Mobile Tools for Java
Release 1.0

org.eclipse.mtj.core
Class MTJCoreErrors

java.lang.Object
  extended by org.eclipse.mtj.core.MTJCoreErrors

public class MTJCoreErrors
extends Object

This interface holds the error, warning codes for the MTJ org.eclipse.mtj.core package.


Field Summary
static int CORE_ERROR_BASE
           
static int CORE_INTERNAL_BASE
           
static int CORE_WARNING_BASE
           
static String MESSAGE_PREFIX
          This string represents the prefix used in looking up messages for error and warning codes.
static int SIGNING_BAD_KEY_TYPE
           
static int SIGNING_BAD_KEYSTORE_OR_PASSWORD
           
static int SIGNING_CERTIFICATE_ENCODING
           
static int SIGNING_COULDNT_LOAD_CERTIFICATE
           
static int SIGNING_INTERNAL_MISSING_KEYCHAINSET
           
static int SIGNING_INTERNAL_UNABLE_TO_BUILD_KEYRING_URL
           
static int SIGNING_INVALID_CERTIFICATE_CHAIN
           
static int SIGNING_INVALID_KEY
           
static int SIGNING_INVALID_KEY_PASSWORD
           
static int SIGNING_KEY_NOT_FOUND
           
static int SIGNING_KEYSTORE_TYPE_NOT_AVAILABLE
           
static int SIGNING_MISSING_CERTIFICATES
           
static int SIGNING_MISSING_KEYSTORE_INTEGRITY_ALGORITHM
           
static int SIGNING_NO_SUCH_ALGORITHM
           
static int SIGNING_PROVIDER_NOT_CONFIGURED
           
static int SIGNING_SIGNATURE_EXCEPTION
           
 
Constructor Summary
MTJCoreErrors()
           
 
Method Summary
static String getErrorMessage(int nCode)
          This routine returns the message associated with a particular error code or warning.
static void throwCoreExceptionError(int code)
          This routine throws a CoreException with a status code of "ERROR", the specified error code, and a message that is internationalized.
static void throwCoreExceptionError(int code, Throwable e)
          This routine throws a CoreException with a status code of "ERROR", the specified error code, and a message that is internationalized.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MESSAGE_PREFIX

public static final String MESSAGE_PREFIX
This string represents the prefix used in looking up messages for error and warning codes.

See Also:
Constant Field Values

CORE_ERROR_BASE

public static final int CORE_ERROR_BASE
See Also:
Constant Field Values

SIGNING_BAD_KEYSTORE_OR_PASSWORD

public static final int SIGNING_BAD_KEYSTORE_OR_PASSWORD
See Also:
Constant Field Values

SIGNING_KEYSTORE_TYPE_NOT_AVAILABLE

public static final int SIGNING_KEYSTORE_TYPE_NOT_AVAILABLE
See Also:
Constant Field Values

SIGNING_PROVIDER_NOT_CONFIGURED

public static final int SIGNING_PROVIDER_NOT_CONFIGURED
See Also:
Constant Field Values

SIGNING_MISSING_KEYSTORE_INTEGRITY_ALGORITHM

public static final int SIGNING_MISSING_KEYSTORE_INTEGRITY_ALGORITHM
See Also:
Constant Field Values

SIGNING_COULDNT_LOAD_CERTIFICATE

public static final int SIGNING_COULDNT_LOAD_CERTIFICATE
See Also:
Constant Field Values

SIGNING_KEY_NOT_FOUND

public static final int SIGNING_KEY_NOT_FOUND
See Also:
Constant Field Values

SIGNING_INVALID_KEY_PASSWORD

public static final int SIGNING_INVALID_KEY_PASSWORD
See Also:
Constant Field Values

SIGNING_BAD_KEY_TYPE

public static final int SIGNING_BAD_KEY_TYPE
See Also:
Constant Field Values

SIGNING_INVALID_CERTIFICATE_CHAIN

public static final int SIGNING_INVALID_CERTIFICATE_CHAIN
See Also:
Constant Field Values

SIGNING_MISSING_CERTIFICATES

public static final int SIGNING_MISSING_CERTIFICATES
See Also:
Constant Field Values

SIGNING_INVALID_KEY

public static final int SIGNING_INVALID_KEY
See Also:
Constant Field Values

SIGNING_NO_SUCH_ALGORITHM

public static final int SIGNING_NO_SUCH_ALGORITHM
See Also:
Constant Field Values

SIGNING_SIGNATURE_EXCEPTION

public static final int SIGNING_SIGNATURE_EXCEPTION
See Also:
Constant Field Values

SIGNING_CERTIFICATE_ENCODING

public static final int SIGNING_CERTIFICATE_ENCODING
See Also:
Constant Field Values

CORE_WARNING_BASE

public static final int CORE_WARNING_BASE
See Also:
Constant Field Values

CORE_INTERNAL_BASE

public static final int CORE_INTERNAL_BASE
See Also:
Constant Field Values

SIGNING_INTERNAL_MISSING_KEYCHAINSET

public static final int SIGNING_INTERNAL_MISSING_KEYCHAINSET
See Also:
Constant Field Values

SIGNING_INTERNAL_UNABLE_TO_BUILD_KEYRING_URL

public static final int SIGNING_INTERNAL_UNABLE_TO_BUILD_KEYRING_URL
See Also:
Constant Field Values
Constructor Detail

MTJCoreErrors

public MTJCoreErrors()
Method Detail

getErrorMessage

public static final String getErrorMessage(int nCode)
This routine returns the message associated with a particular error code or warning. If there's a specific text message in the resource bundle, associated with this code, that one is returned. Otherwise, a default message is used. In either case, the error code is optionally (based on the string contents) substituted into the message.

Parameters:
nCode - The error code.
Returns:

throwCoreExceptionError

public static void throwCoreExceptionError(int code)
                                    throws CoreException
This routine throws a CoreException with a status code of "ERROR", the specified error code, and a message that is internationalized.

Parameters:
code -
Throws:
CoreException

throwCoreExceptionError

public static void throwCoreExceptionError(int code,
                                           Throwable e)
                                    throws CoreException
This routine throws a CoreException with a status code of "ERROR", the specified error code, and a message that is internationalized.

Parameters:
code -
Throws:
CoreException

Mobile Tools for Java
Release 1.0