org.opends.messages
Enum Severity

java.lang.Object
  extended by java.lang.Enum<Severity>
      extended by org.opends.messages.Severity
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<Severity>

@PublicAPI(stability=UNCOMMITTED,
           mayInstantiate=false,
           mayExtend=false,
           mayInvoke=true)
public enum Severity
extends java.lang.Enum<Severity>

Defines values for message severity. Severities contain an integer value that can be used for bitwise operations as well as a short abbreviated string form of each value.


Enum Constant Summary
DEBUG
          The severity that will be used for debug messages.
FATAL_ERROR
          The severity that will be used for fatal error messages.
INFORMATION
          The severity that will be used for informational messages.
MILD_ERROR
          The severity that will be used for mild error messages.
MILD_WARNING
          The severity that will be used for mild warning messages.
NOTICE
          The severity that will be used for important informational messages.
SEVERE_ERROR
          The severity that will be used for severe error messages.
SEVERE_WARNING
          The severity that will be used for severe warning messages.
 
Method Summary
 int getMask()
          Returns the mask associated with this Severity.
static java.util.Set<java.lang.String> getPropertyKeyFormSet()
          Returns a set of string representing all Severitys' abbreviated representations.
 java.lang.String messageDesciptorName()
          Gets the abbreviated form of this Severity.
static Severity parseMask(int mask)
          Obtains the Severity associated with a given mask value.
static Severity parseMessageId(int msgId)
          Obtains the Severity associated with the the input message ID msgId.
static Severity parseString(java.lang.String s)
          Returns the Severity associated with the input string s which can either be a severity's name or messageDescriptorForm.
 java.lang.String propertyKeyFormName()
          Gets the name of this severity as it must appear in the property key name in a messages file.
static Severity valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static Severity[] 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

INFORMATION

public static final Severity INFORMATION
The severity that will be used for informational messages.


MILD_WARNING

public static final Severity MILD_WARNING
The severity that will be used for mild warning messages.


SEVERE_WARNING

public static final Severity SEVERE_WARNING
The severity that will be used for severe warning messages.


MILD_ERROR

public static final Severity MILD_ERROR
The severity that will be used for mild error messages.


SEVERE_ERROR

public static final Severity SEVERE_ERROR
The severity that will be used for severe error messages.


FATAL_ERROR

public static final Severity FATAL_ERROR
The severity that will be used for fatal error messages.


DEBUG

public static final Severity DEBUG
The severity that will be used for debug messages.


NOTICE

public static final Severity NOTICE
The severity that will be used for important informational messages.

Method Detail

values

public static Severity[] 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 (Severity c : Severity.values())
    System.out.println(c);

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

valueOf

public static Severity 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

getPropertyKeyFormSet

public static java.util.Set<java.lang.String> getPropertyKeyFormSet()
Returns a set of string representing all Severitys' abbreviated representations.

Returns:
set of messageDescriptorForm strings

parseMask

public static Severity parseMask(int mask)
Obtains the Severity associated with a given mask value.

Parameters:
mask - for which a Severity is obtained.
Returns:
Severity associated with mask

parseString

public static Severity parseString(java.lang.String s)
Returns the Severity associated with the input string s which can either be a severity's name or messageDescriptorForm.

Parameters:
s - Severity name or messageDescriptorForm
Returns:
Severity assocated with s

parseMessageId

public static Severity parseMessageId(int msgId)
Obtains the Severity associated with the the input message ID msgId.

Parameters:
msgId - int message ID
Returns:
Severity assocated with the ID

getMask

public int getMask()
Returns the mask associated with this Severity.

Returns:
mask for this severity

messageDesciptorName

public java.lang.String messageDesciptorName()
Gets the abbreviated form of this Severity.

Returns:
String abbreviated form

propertyKeyFormName

public java.lang.String propertyKeyFormName()
Gets the name of this severity as it must appear in the property key name in a messages file.

Returns:
name of this severity