org.ogf.saga.task
Enum TaskMode

java.lang.Object
  extended by java.lang.Enum<TaskMode>
      extended by org.ogf.saga.task.TaskMode
All Implemented Interfaces:
Serializable, Comparable<TaskMode>

public enum TaskMode
extends Enum<TaskMode>

This enumeration type describes the possible ways to create a task: Asynchronous (the task is started in RUNNING state), Task (the task is started in NEW state), or Synchronous (the task is started and waited for).


Enum Constant Summary
ASYNC
          The task is started in State.RUNNING state, that is, the Task.run() call is implicit.
SYNC
          The task is started in State.RUNNING state, and is waited for.
TASK
          The task is started in State.NEW state.
 
Method Summary
 int getValue()
          Returns the integer value of this enumeration literal.
static TaskMode valueOf(String name)
          Returns the enum constant of this type with the specified name.
static TaskMode[] 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

ASYNC

public static final TaskMode ASYNC
The task is started in State.RUNNING state, that is, the Task.run() call is implicit.


TASK

public static final TaskMode TASK
The task is started in State.NEW state.


SYNC

public static final TaskMode SYNC
The task is started in State.RUNNING state, and is waited for.

Method Detail

values

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

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

valueOf

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

getValue

public int getValue()
Returns the integer value of this enumeration literal.

Returns:
the value.


Copyright © 2014 Open Grid Forum. All rights reserved.