org.javasimon.callback
Enum Callback.Event

java.lang.Object
  extended by java.lang.Enum<Callback.Event>
      extended by org.javasimon.callback.Callback.Event
All Implemented Interfaces:
Serializable, Comparable<Callback.Event>
Enclosing interface:
Callback

public static enum Callback.Event
extends Enum<Callback.Event>

Enumeration of all supported callback actions. ALL is meta-action usable in configurations meaning that the configuration entry applies to all actions (any action). In callback configuration action names in lowercase and with _ replaced for - can be used (e.g. "counter-increase" instead for COUNTER_INCREASE.

Event codes are used for configuration purposes instead of enum literals.


Enum Constant Summary
ALL
          Meta-action designating all actions (or any action in rules).
COUNTER_DECREASE
          Counter decreased.
COUNTER_INCREASE
          Counter increased.
COUNTER_SET
          Counter set to arbitrary value.
CREATED
          Creation of a Simon.
DESTROYED
          Removing of a Simon.
MANAGER_CLEAR
          Clearing of the manager.
MESSAGE
          Event producing arbitrary message.
RESET
          Reset of the Simon.
STOPWATCH_ADD
          Adding value to the stopwatch.
STOPWATCH_START
          Start of the stopwatch.
STOPWATCH_STOP
          Stop of the stopwatch.
WARNING
          Warning related to the manager.
 
Field Summary
private  String code
           
private static Map<String,Callback.Event> codeValues
           
 
Method Summary
static Callback.Event forCode(String code)
          Returns event for String code used in XML configuration.
static Callback.Event valueOf(String name)
          Returns the enum constant of this type with the specified name.
static Callback.Event[] 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

ALL

public static final Callback.Event ALL
Meta-action designating all actions (or any action in rules).


RESET

public static final Callback.Event RESET
Reset of the Simon.


STOPWATCH_START

public static final Callback.Event STOPWATCH_START
Start of the stopwatch.


STOPWATCH_STOP

public static final Callback.Event STOPWATCH_STOP
Stop of the stopwatch.


STOPWATCH_ADD

public static final Callback.Event STOPWATCH_ADD
Adding value to the stopwatch.


COUNTER_INCREASE

public static final Callback.Event COUNTER_INCREASE
Counter increased.


COUNTER_DECREASE

public static final Callback.Event COUNTER_DECREASE
Counter decreased.


COUNTER_SET

public static final Callback.Event COUNTER_SET
Counter set to arbitrary value.


CREATED

public static final Callback.Event CREATED
Creation of a Simon.


DESTROYED

public static final Callback.Event DESTROYED
Removing of a Simon.


MANAGER_CLEAR

public static final Callback.Event MANAGER_CLEAR
Clearing of the manager.


MESSAGE

public static final Callback.Event MESSAGE
Event producing arbitrary message.


WARNING

public static final Callback.Event WARNING
Warning related to the manager.

Field Detail

codeValues

private static Map<String,Callback.Event> codeValues

code

private String code
Method Detail

values

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

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

valueOf

public static Callback.Event valueOf(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:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

forCode

public static Callback.Event forCode(String code)
Returns event for String code used in XML configuration.

Parameters:
code - String code
Returns:
Event object


Copyright © 2013. All Rights Reserved.