org.springframework.conversation
Enum ConversationType

java.lang.Object
  extended by java.lang.Enum<ConversationType>
      extended by org.springframework.conversation.ConversationType
All Implemented Interfaces:
Serializable, Comparable<ConversationType>

public enum ConversationType
extends Enum<ConversationType>

The conversation type is used while starting a new conversation and declares how the conversation manager should create and start it as well how to end the current conversation, if any.

Since:
3.1
Author:
Micha Kiener

Enum Constant Summary
ISOLATED
          The type ISOLATED is basically the same as NESTED but will isolate the state from its parent.
NESTED
          The type NESTED will create a new conversation and add it as a child conversation to the current one, if available.
NEW
          The type NEW creates a new root conversation and will end a current one, if any.
 
Method Summary
static ConversationType valueOf(String name)
          Returns the enum constant of this type with the specified name.
static ConversationType[] 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

NEW

public static final ConversationType NEW
The type NEW creates a new root conversation and will end a current one, if any.


NESTED

public static final ConversationType NESTED
The type NESTED will create a new conversation and add it as a child conversation to the current one, if available. If there is no current conversation, this type is the same as NEW. A nested conversation will inherit the state from its parent.


ISOLATED

public static final ConversationType ISOLATED
The type ISOLATED is basically the same as NESTED but will isolate the state from its parent. While a nested conversation will inherit the state from its parent, an isolated one does not but rather has its own state.

Method Detail

values

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

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

valueOf

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