com.wutka.util
Class LogSeverity
java.lang.Object
|
+--com.wutka.util.LogSeverity
- public class LogSeverity
- extends java.lang.Object
An enumeration class providing numeric and string versions of the
various log severity levels.
|
Constructor Summary |
protected |
LogSeverity(int aLevel,
java.lang.String aName)
Creates a log severity. |
|
Method Summary |
boolean |
equals(java.lang.Object other)
Compares this object with another |
static LogSeverity |
getSeverity(java.lang.String aName)
Finds the LogSeverity instance associated with a particular name. |
java.lang.String |
getSeverityName()
Return the name for this severity |
int |
getSeverityValue()
Returns the numeric value for this severity |
int |
hashCode()
Computes the hash code for this object |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
nameLookup
protected static java.util.Hashtable nameLookup
DEBUG
public static final LogSeverity DEBUG
INFORMATION
public static final LogSeverity INFORMATION
WARNING
public static final LogSeverity WARNING
ERROR
public static final LogSeverity ERROR
level
protected int level
name
protected java.lang.String name
LogSeverity
protected LogSeverity(int aLevel,
java.lang.String aName)
- Creates a log severity.
- Parameters:
aLevel - The level of the severityaName - The name of the severity level
getSeverity
public static LogSeverity getSeverity(java.lang.String aName)
- Finds the LogSeverity instance associated with a particular name.
- Parameters:
aName - The name of the severity to locate- Returns:
- The severity associated with the name, or null if none is found.
getSeverityValue
public int getSeverityValue()
- Returns the numeric value for this severity
- Returns:
- The numeric value for this severity
getSeverityName
public java.lang.String getSeverityName()
- Return the name for this severity
- Returns:
- The name for this severity
hashCode
public int hashCode()
- Computes the hash code for this object
- Overrides:
hashCode in class java.lang.Object
equals
public boolean equals(java.lang.Object other)
- Compares this object with another
- Overrides:
equals in class java.lang.Object