Enum Class ExchangePattern

java.lang.Object
java.lang.Enum<ExchangePattern>
org.apache.camel.ExchangePattern
All Implemented Interfaces:
Serializable, Comparable<ExchangePattern>, Constable

public enum ExchangePattern extends Enum<ExchangePattern>
The message exchange pattern of an Exchange, indicating whether the caller expects a reply.

InOnly is used for fire-and-forget messaging: the caller sends a message and does not wait for a response. InOut is used for request-reply messaging: the caller sends a message and blocks until a response is received.

The pattern is set on the Exchange and is checked by the Camel routing engine and endpoints to determine how to handle the interaction.

See Also:
  • Enum Constant Details

    • InOnly

      public static final ExchangePattern InOnly
      Fire-and-forget: the caller sends a message and does not expect a reply.
    • InOut

      public static final ExchangePattern InOut
      Request-reply: the caller sends a message and expects a response.
  • Method Details

    • values

      public static ExchangePattern[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static ExchangePattern valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      NullPointerException - if the argument is null
    • isInCapable

      public boolean isInCapable()
      Return true if there can be an IN message
    • isOutCapable

      public boolean isOutCapable()
      Return true if there can be an OUT message
    • asEnum

      public static ExchangePattern asEnum(String value)