com.caucho.message
Enum SettleMode

java.lang.Object
  extended by java.lang.Enum<SettleMode>
      extended by com.caucho.message.SettleMode
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<SettleMode>

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

Selects when a message is considered delivered and can be considered settled and forgotten by the sender. The settle mode can range from fire-and-forget (ALWAYS), to exactly-once (ACKNOWLEDGE).


Enum Constant Summary
ALWAYS
          ALWAYS settles the message immediately without waiting for any confirmation.
AT_LEAST_ONCE
          AT_LEAST_ONCE settles the message with the receiver has returned an ack.
EXACTLY_ONCE
          EXACTLY_ONCE settles the message with the receiver has acknowledged the message, and the sender has acknowledge receipt of the ack (double ack.)
 
Method Summary
static SettleMode valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static SettleMode[] 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

ALWAYS

public static final SettleMode ALWAYS
ALWAYS settles the message immediately without waiting for any confirmation. ALWAYS is the fire-and-forget, at-most-once mode where the client sender will not receive any notification on failure.


AT_LEAST_ONCE

public static final SettleMode AT_LEAST_ONCE
AT_LEAST_ONCE settles the message with the receiver has returned an ack.


EXACTLY_ONCE

public static final SettleMode EXACTLY_ONCE
EXACTLY_ONCE settles the message with the receiver has acknowledged the message, and the sender has acknowledge receipt of the ack (double ack.)

Method Detail

values

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

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

valueOf

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