net.rim.device.api.io.file
Class FileIOException

java.lang.Object
  |
  +--java.lang.Throwable
        |
        +--java.lang.Exception
              |
              +--java.io.IOException
                    |
                    +--net.rim.device.api.io.file.FileIOException

public class FileIOException
extends IOException

The FileIOException is a subclass of the IOException which can be used to provide more detail without having to rely on parsing a string. The error code of the IOException can be retrieved via the getErrorCode() method.

Since:
JDE 4.2.0

Field Summary
static int CONTENT_BUILT_IN
          The operation is not allowed because the content is built-in (preloaded).
static int DIRECTORY_ALREADY_EXISTS
          The directory already exists.
static int DIRECTORY_FULL
          The directory is full.
static int DIRECTORY_NOT_EMPTY
          The directory is not empty.
static int DIRECTORY_NOT_FOUND
          The directory cannot be found.
static int FILE_BUSY
          The operation failed because file is currently opened.
static int FILE_HANDLES_OPEN
          The file handle used is already open.
static int FILE_NOT_OPEN
          The file is no longer open.
static int FILE_SYSTEM_UNAVAILABLE
          The file system is unavailable.
static int FILE_TOO_LARGE
          The operation failed because the file create is too large for the system.
static int FILENAME_ALREADY_EXISTS
          The filename already exists.
static int FILENAME_NOT_FOUND
          The filename cannot be found.
static int FILENAME_TOO_LONG
          The filename is too long.
static int FILESYSTEM_EMPTY
          The file system is empty.
static int FILESYSTEM_FULL
          The file system is full.
static int FS_ALREADY_MOUNTED
          The file system is already mounted.
static int FS_LOCKED_BY_OTHER_DEVICE
          The operation failed because the sdcard is already locked by another device.
static int FS_NOT_MOUNTED
          The file system is not mounted.
static int FS_VERIFICATION_FAILED
          The file system failed to be mounted because of a verification error.
static int GENERAL_ERROR
          A general error occurred.
static int INVALID_CHARACTERS
          The string specified contains invalid characters.
static int INVALID_HANDLE
          The file system handle used in the file operation is currently invalid.
static int INVALID_OPERATION
          The operation requested is invalid.
static int INVALID_PARAMETER
          The file system received an invalid parameter.
static int IS_A_DIRECTORY
          The filename requested is a directory.
static int MEDIUM_NOT_FORMATTED
          The medium is not formatted.
static int NO_FREE_HANDLES
          There are no more free handles.
static int NO_SUCH_ROOT
          The root specified is not available.
static int NOT_A_DIRECTORY
          The filename requested is not a directory.
static int NOT_A_FILE
          The filename requested is not a file.
static int OS_BUSY
          The operating system is busy.
static int STREAM_ALREADY_OPENED
          The requested stream is already opened.
 
Constructor Summary
FileIOException(int errorCode)
          Create a FileIOException with the specified error code.
 
Method Summary
 int getErrorCode()
          Retrieves the error code.
 String getMessage()
          Retrieves the associated error message.
 
Methods inherited from class java.lang.Throwable
printStackTrace, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

CONTENT_BUILT_IN

public static final int CONTENT_BUILT_IN
The operation is not allowed because the content is built-in (preloaded).
Since:
JDE 4.2.0

DIRECTORY_ALREADY_EXISTS

public static final int DIRECTORY_ALREADY_EXISTS
The directory already exists.
Since:
JDE 4.2.0

DIRECTORY_FULL

public static final int DIRECTORY_FULL
The directory is full.
Since:
JDE 4.2.0

DIRECTORY_NOT_EMPTY

public static final int DIRECTORY_NOT_EMPTY
The directory is not empty.
Since:
JDE 4.2.0

DIRECTORY_NOT_FOUND

public static final int DIRECTORY_NOT_FOUND
The directory cannot be found.
Since:
JDE 4.2.0

FILE_BUSY

public static final int FILE_BUSY
The operation failed because file is currently opened.
Since:
JDE 4.5.0

FILE_HANDLES_OPEN

public static final int FILE_HANDLES_OPEN
The file handle used is already open.
Since:
JDE 4.2.0

FILE_NOT_OPEN

public static final int FILE_NOT_OPEN
The file is no longer open.
Since:
JDE 4.2.0

FILE_SYSTEM_UNAVAILABLE

public static final int FILE_SYSTEM_UNAVAILABLE
The file system is unavailable.
Since:
JDE 4.2.0

FILE_TOO_LARGE

public static final int FILE_TOO_LARGE
The operation failed because the file create is too large for the system.
Since:
JDE 4.2.0

FILENAME_ALREADY_EXISTS

public static final int FILENAME_ALREADY_EXISTS
The filename already exists.
Since:
JDE 4.2.0

FILENAME_NOT_FOUND

public static final int FILENAME_NOT_FOUND
The filename cannot be found.
Since:
JDE 4.2.0

FILENAME_TOO_LONG

public static final int FILENAME_TOO_LONG
The filename is too long.
Since:
JDE 4.2.0

FILESYSTEM_EMPTY

public static final int FILESYSTEM_EMPTY
The file system is empty.
Since:
JDE 4.2.0

FILESYSTEM_FULL

public static final int FILESYSTEM_FULL
The file system is full.
Since:
JDE 4.2.0

FS_ALREADY_MOUNTED

public static final int FS_ALREADY_MOUNTED
The file system is already mounted.
Since:
JDE 4.2.0

FS_LOCKED_BY_OTHER_DEVICE

public static final int FS_LOCKED_BY_OTHER_DEVICE
The operation failed because the sdcard is already locked by another device.
Since:
JDE 4.6.0

FS_NOT_MOUNTED

public static final int FS_NOT_MOUNTED
The file system is not mounted.
Since:
JDE 4.2.0

FS_VERIFICATION_FAILED

public static final int FS_VERIFICATION_FAILED
The file system failed to be mounted because of a verification error.
Since:
JDE 4.2.1

GENERAL_ERROR

public static final int GENERAL_ERROR
A general error occurred.
Since:
JDE 4.2.0

INVALID_CHARACTERS

public static final int INVALID_CHARACTERS
The string specified contains invalid characters.
Since:
JDE 4.2.0

INVALID_HANDLE

public static final int INVALID_HANDLE
The file system handle used in the file operation is currently invalid.
Since:
JDE 4.2.0

INVALID_OPERATION

public static final int INVALID_OPERATION
The operation requested is invalid.
Since:
JDE 4.2.0

INVALID_PARAMETER

public static final int INVALID_PARAMETER
The file system received an invalid parameter.
Since:
JDE 4.2.0

IS_A_DIRECTORY

public static final int IS_A_DIRECTORY
The filename requested is a directory.
Since:
JDE 4.2.0

MEDIUM_NOT_FORMATTED

public static final int MEDIUM_NOT_FORMATTED
The medium is not formatted.
Since:
JDE 4.2.0

NO_FREE_HANDLES

public static final int NO_FREE_HANDLES
There are no more free handles.
Since:
JDE 4.2.0

NO_SUCH_ROOT

public static final int NO_SUCH_ROOT
The root specified is not available.
Since:
JDE 4.2.0

NOT_A_DIRECTORY

public static final int NOT_A_DIRECTORY
The filename requested is not a directory.
Since:
JDE 4.2.0

NOT_A_FILE

public static final int NOT_A_FILE
The filename requested is not a file.
Since:
JDE 4.2.0

OS_BUSY

public static final int OS_BUSY
The operating system is busy.
Since:
JDE 4.2.0

STREAM_ALREADY_OPENED

public static final int STREAM_ALREADY_OPENED
The requested stream is already opened.
Since:
JDE 4.2.0
Constructor Detail

FileIOException

public FileIOException(int errorCode)
Create a FileIOException with the specified error code.
Parameters:
errorCode - The error code is an enumeration of constants exposed in this class.
Since:
JDE 4.2.0
Method Detail

getErrorCode

public int getErrorCode()
Retrieves the error code.
Returns:
Return the error code.
Since:
JDE 4.2.0

getMessage

public String getMessage()
Retrieves the associated error message.
Overrides:
getMessage in class Throwable
Returns:
Return the associated textual error message.
Since:
JDE 4.2.0



Copyright 1999-2009 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
Copyright 2002-2003 Nokia Corporation All Rights Reserved.
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.