|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.sadun.util.sis.StateInfoSupport
Plug-in class for adding state information support to an mbean.
The Mbean owning an instance can record state information entries related to a specific key and obtain a String to provide the console user with a log.
Constructor Summary | |
StateInfoSupport()
|
Method Summary | |
void |
addEntry(java.lang.String description)
Add a entry for the same key as the last addEntry operation, containing a textual description. |
void |
addEntry(java.lang.String key,
java.lang.String description)
Add a entry for the given key, containing a textual description |
void |
addEntry(java.lang.String key,
java.lang.String description,
java.lang.Throwable e)
Add a entry for the given key, containing a textual description and a given exception object |
void |
addEntry(java.lang.String description,
java.lang.Throwable e)
Add a entry for the same key as the last addEntry operation, containing a textual description anda given exception object. |
int |
getLevel()
Returns the level. |
java.lang.String |
getStateDescription(java.lang.String key)
Return a state log for the given key. |
static void |
main(java.lang.String[] args)
|
void |
setLevel(int level)
Sets the level. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public StateInfoSupport()
Method Detail |
public void addEntry(java.lang.String key, java.lang.String description)
public void addEntry(java.lang.String key, java.lang.String description, java.lang.Throwable e)
public void addEntry(java.lang.String description)
This method can be invoked only after one of the addEntry overloads with key parameters have been invoked. * @param description
public void addEntry(java.lang.String description, java.lang.Throwable e)
This method can be invoked only after one of the addEntry overloads with key parameters have been invoked. * @param description * @param e
public java.lang.String getStateDescription(java.lang.String key)
If the key does not exist, null is returned. * @param key the key of interest. * @return a state log for the given key, or null. If key is null or the empty string, all entries are descripted.
public static void main(java.lang.String[] args) throws java.lang.Exception
java.lang.Exception
public int getLevel()
public void setLevel(int level)
level
- The level to set
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |