dk.netarkivet.harvester.webinterface
Enum TrapActionEnum

java.lang.Object
  extended by java.lang.Enum<TrapActionEnum>
      extended by dk.netarkivet.harvester.webinterface.TrapActionEnum
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<TrapActionEnum>

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

Represents the various actions which can be carried out to modify Global Crawler Traps.


Enum Constant Summary
ACTIVATE
          Change an existing list from inactive to active.
CREATE_OR_UPDATE
          Corresponds to uploading of a global crawler trap list, either as a new list or as an update to an existing list.
DEACTIVATE
          Change an existing list from active to inactive.
DELETE
          Action to delete an existing list.
NULL_ACTION
          Do nothing.
READ
          Action to download an existing list to browser or file.
 
Method Summary
abstract  TrapAction getTrapAction()
          Get the concrete TrapAction which can process this request.
static TrapActionEnum valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static TrapActionEnum[] 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

CREATE_OR_UPDATE

public static final TrapActionEnum CREATE_OR_UPDATE
Corresponds to uploading of a global crawler trap list, either as a new list or as an update to an existing list.


READ

public static final TrapActionEnum READ
Action to download an existing list to browser or file.


DELETE

public static final TrapActionEnum DELETE
Action to delete an existing list.


ACTIVATE

public static final TrapActionEnum ACTIVATE
Change an existing list from inactive to active.


DEACTIVATE

public static final TrapActionEnum DEACTIVATE
Change an existing list from active to inactive.


NULL_ACTION

public static final TrapActionEnum NULL_ACTION
Do nothing. The existence of a null action is an architectural convenience.

Method Detail

values

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

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

valueOf

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

getTrapAction

public abstract TrapAction getTrapAction()
Get the concrete TrapAction which can process this request.

Returns:
the correct TrapAction for this request type.