net.rim.device.api.io
Class File

java.lang.Object
  extended by net.rim.device.api.io.File

Deprecated.

public final class File
extends Object

Provides low-level access to various file systems. This class provides acces to only the iDEN file system. To access file systems such as the device store or SDCard use the javax.microedition.io.file classes.

See Also:
FileConnection
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

Field Summary
Category: Signed static int FILESYSTEM_PATRIOT
          Deprecated.  
 
Method Summary
Category: Signed static void delete(int fs, String fileName)
          Deprecated. use javax.microedition.io.file
Category: Signed static String findFirst(int fs, String pattern)
          Deprecated. use javax.microedition.io.file
Category: Signed static boolean findFirst(int fs, String pattern, FileInfo fileInfo)
          Deprecated. use javax.microedition.io.file
Category: Signed static String findNext(int fs)
          Deprecated. use javax.microedition.io.file
Category: Signed static boolean findNext(int fs, FileInfo fileInfo)
          Deprecated. use javax.microedition.io.file
Category: Signed static long getFileSize(int fs, String fileName)
          Deprecated. use javax.microedition.io.file
Category: Signed static long getFileSystemFreeSpace(int fs)
          Deprecated. use javax.microedition.io.file
Category: Signed static long getFileSystemTotalSpace(int fs)
          Deprecated. use javax.microedition.io.file
Category: Signed static boolean isFileSystemSupported(int fs)
          Deprecated.  
Category: Signed static boolean isSupported()
          Deprecated.  
Category: Signed static void rename(int fs, String oldFileName, String newFileName)
          Deprecated. use javax.microedition.io.file
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 



Field Detail

FILESYSTEM_PATRIOT

public static final int FILESYSTEM_PATRIOT
Deprecated. 
File system built into iDEN devices.

See Also:
Constant Field Values
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2


Method Detail

isSupported

public static final boolean isSupported()
Deprecated. 

Determines if this device supports one or more file systems.

Returns:
True if this device provides access to one or more file systems.
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

isFileSystemSupported

public static final boolean isFileSystemSupported(int fs)
Deprecated. 

Determines if this device supports the specified file system.

Parameters:
fs - One of the FILESYSTEM_ values.
Returns:
True if this device provides access to the specified file system.
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

delete

public static void delete(int fs,
                          String fileName)
                   throws IOException
Deprecated. use javax.microedition.io.file

Deletes the specified file.

Parameters:
fs - One of the FILESYSTEM_ values.
fileName - The name of the file.
Throws:
IOException - if a file with the specified name does not exist on the specified filesystem.
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

rename

public static void rename(int fs,
                          String oldFileName,
                          String newFileName)
                   throws IOException
Deprecated. use javax.microedition.io.file

Renames the specified file.

Parameters:
fs - One of the FILESYSTEM_ values.
oldFileName - The name of the file.
newFileName - The new name for the file.
Throws:
IOException
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

getFileSystemTotalSpace

public static long getFileSystemTotalSpace(int fs)
                                    throws IOException
Deprecated. use javax.microedition.io.file

Retrieves the total size for the specified file system.

Parameters:
fs - One of the FILESYSTEM_ values.
Returns:
The total number of bytes in the file system.
Throws:
IOException
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

getFileSystemFreeSpace

public static long getFileSystemFreeSpace(int fs)
                                   throws IOException
Deprecated. use javax.microedition.io.file

Retrieves the free space for the specified file system.

Parameters:
fs - One of the FILESYSTEM_ values.
Returns:
The number of available bytes in the file system.
Throws:
IOException
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

getFileSize

public static long getFileSize(int fs,
                               String fileName)
                        throws IOException
Deprecated. use javax.microedition.io.file

Retrieves the size of the specified file.

Note: Calling this method resets any findFirst or findNext query in progress.

Parameters:
fs - One of the FILESYSTEM_ values.
fileName - The name of the file.
Returns:
The size of the file in bytes.
Throws:
IOException
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

findFirst

public static String findFirst(int fs,
                               String pattern)
                        throws IOException
Deprecated. use javax.microedition.io.file

Finds the first file that matches the specified pattern.

Parameters:
fs - One of the FILESYSTEM_ values.
pattern - A pattern to search within file names. This pattern can include wildcard characters (*).
Returns:
The file name of the first file that matches the pattern specified, or null if no file matches.
Throws:
IOException
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

findFirst

public static boolean findFirst(int fs,
                                String pattern,
                                FileInfo fileInfo)
                         throws IOException
Deprecated. use javax.microedition.io.file

Finds the first file that matches the specified pattern.

Parameters:
fs - One of the FILESYSTEM_ values.
pattern - A pattern to search within file names. This pattern can include wildcard characters (*).
fileInfo - A FileInfo instance to receive the file information.
Returns:
True if a file was found that matches the pattern specifed; false otherwise.
Throws:
IOException
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

findNext

public static String findNext(int fs)
                       throws IOException
Deprecated. use javax.microedition.io.file

Finds the next file that matches the specified pattern.

Parameters:
fs - One of the FILESYSTEM_ values.
Returns:
The next file that matches the pattern specified in a previous call to findFirst, or null if there are no more matches.
Throws:
IOException
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2

findNext

public static boolean findNext(int fs,
                               FileInfo fileInfo)
                        throws IOException
Deprecated. use javax.microedition.io.file

Finds the next file that matches the specified pattern.

Parameters:
fs - One of the FILESYSTEM_ values.
fileInfo - A FileInfo instance to receive the file information.
Returns:
True if a file was found matching the pattern specifed; false otherwise.
Throws:
IOException
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Since:
BlackBerry API 4.0.2





Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal