com.paragon.open.dictionary.api
Enum Error

java.lang.Object
  extended by java.lang.Enum<Error>
      extended by com.paragon.open.dictionary.api.Error
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<Error>

public enum Error
extends java.lang.Enum<Error>

Possible errors.

Author:
Sergey Solomatin (Sergey_Solomatin@penreader.com)

Enum Constant Summary
DATABASE_IS_NOT_AVAILABLE
          A dictionary database is not available at the moment.
ERROR_STATE_OF_THE_APPLICATION
          Invalid state of the application.
INCORRECT_PARAMETERS
          Incorrect parameters.
INTERNAL_ERROR
          An internal error.
 
Method Summary
 java.lang.String getMessage()
          Get a detailed message of the error.
 java.lang.String getName()
          Get the name of the error.
static Error valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static Error[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

INTERNAL_ERROR

public static final Error INTERNAL_ERROR
An internal error. See getMessage() for a detaled message.


DATABASE_IS_NOT_AVAILABLE

public static final Error DATABASE_IS_NOT_AVAILABLE
A dictionary database is not available at the moment.


ERROR_STATE_OF_THE_APPLICATION

public static final Error ERROR_STATE_OF_THE_APPLICATION
Invalid state of the application. Case when the dictionary application failed the Internet verification procedure or not registered.


INCORRECT_PARAMETERS

public static final Error INCORRECT_PARAMETERS
Incorrect parameters. See getMessage() for a detaled message.

Method Detail

values

public static Error[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (Error c : Error.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static Error valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

getName

public java.lang.String getName()
Get the name of the error.

Returns:
name

getMessage

public java.lang.String getMessage()
Get a detailed message of the error.

Returns:
detailed message or null if has not