|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.servicemix.jbi.messaging.MessageExchangeImpl
public abstract class MessageExchangeImpl
A simple message exchange declaration. This is partial, just giving us enough ME function for the doodle. This doesn't add anything new to the current MessageExchange definition.
| Nested Class Summary | |
|---|---|
static class |
MessageExchangeImpl.AgeComparator
Comparator that can be used to sort exchanges according to their "age" in their processing: i.e.: a newly created exchange will be more than a DONE exchange ... |
| Nested classes/interfaces inherited from interface javax.jbi.messaging.MessageExchange |
|---|
javax.jbi.messaging.MessageExchange.Role |
| Field Summary | |
|---|---|
protected static int |
CAN_CONSUMER
|
protected static int |
CAN_OWNER
|
protected static int |
CAN_PROVIDER
|
protected static int |
CAN_SEND
|
protected static int |
CAN_SET_FAULT_MSG
|
protected static int |
CAN_SET_IN_MSG
|
protected static int |
CAN_SET_OUT_MSG
|
protected static int |
CAN_STATUS_ACTIVE
|
protected static int |
CAN_STATUS_DONE
|
protected static int |
CAN_STATUS_ERROR
|
static String |
FAULT
|
static String |
IN
|
protected String |
key
|
protected PojoMarshaler |
marshaler
|
static int |
MAX_MSG_DISPLAY_SIZE
|
protected MessageExchangeImpl |
mirror
|
static String |
OUT
|
protected ExchangePacket |
packet
|
static boolean |
PRESERVE_CONTENT
|
protected boolean |
pushDeliver
|
protected ComponentContextImpl |
sourceContext
|
protected int |
state
|
protected int[][] |
states
|
protected static int |
STATES_CANS
|
protected static int |
STATES_NEXT_DONE
|
protected static int |
STATES_NEXT_ERROR
|
protected static int |
STATES_NEXT_FAULT
|
protected static int |
STATES_NEXT_OUT
|
static int |
SYNC_STATE_ASYNC
|
static int |
SYNC_STATE_SYNC_RECEIVED
|
static int |
SYNC_STATE_SYNC_SENT
|
protected int |
syncState
|
static int |
TX_STATE_CONVEYED
Transaction is being conveyed by the exchange. |
static int |
TX_STATE_ENLISTED
Exchange has been enlisted in the current transaction. |
static int |
TX_STATE_NONE
Exchange is not transactional |
protected Object |
txLock
|
protected int |
txState
|
| Fields inherited from interface javax.jbi.messaging.MessageExchange |
|---|
JTA_TRANSACTION_PROPERTY_NAME |
| Constructor Summary | |
|---|---|
protected |
MessageExchangeImpl()
|
protected |
MessageExchangeImpl(ExchangePacket packet,
int[][] states)
|
|
MessageExchangeImpl(String exchangeId,
URI pattern,
int[][] states)
Constructor |
| Method Summary | |
|---|---|
protected boolean |
can(int c)
|
protected void |
copyFrom(MessageExchangeImpl me)
|
javax.jbi.messaging.Fault |
createFault()
factory method for fault objects |
javax.jbi.messaging.NormalizedMessage |
createMessage()
|
ActivationSpec |
getActivationSpec()
Returns the activation spec that was provided when the component was registered |
ComponentNameSpace |
getDestinationId()
|
javax.jbi.servicedesc.ServiceEndpoint |
getEndpoint()
|
Exception |
getError()
|
String |
getExchangeId()
|
javax.jbi.messaging.Fault |
getFault()
|
javax.jbi.messaging.NormalizedMessage |
getInMessage()
|
QName |
getInterfaceName()
|
String |
getKey()
Compute a unique key for this exchange proxy. |
PojoMarshaler |
getMarshaler()
|
javax.jbi.messaging.NormalizedMessage |
getMessage(String name)
get a NormalizedMessage based on the message reference |
MessageExchangeImpl |
getMirror()
|
QName |
getOperation()
|
javax.jbi.messaging.NormalizedMessage |
getOutMessage()
|
ExchangePacket |
getPacket()
|
URI |
getPattern()
|
Boolean |
getPersistent()
|
Object |
getProperty(String name)
|
Set |
getPropertyNames()
|
javax.jbi.messaging.MessageExchange.Role |
getRole()
|
QName |
getService()
|
ComponentContextImpl |
getSourceContext()
Returns the context which created the message exchange which can then be used for routing |
ComponentNameSpace |
getSourceId()
|
javax.jbi.messaging.ExchangeStatus |
getStatus()
|
int |
getSyncState()
|
Transaction |
getTransactionContext()
|
Object |
getTxLock()
|
int |
getTxState()
|
void |
handleAccept()
|
void |
handleSend(boolean sync)
|
boolean |
isPushDelivery()
|
boolean |
isTransacted()
|
abstract void |
readExternal(ObjectInput in)
|
void |
setDestinationId(ComponentNameSpace destinationId)
|
void |
setEndpoint(javax.jbi.servicedesc.ServiceEndpoint endpoint)
Set an endpoint |
void |
setError(Exception exception)
set the source of a failure |
void |
setFault(javax.jbi.messaging.Fault fault)
set the fault message for the exchange |
void |
setInMessage(javax.jbi.messaging.NormalizedMessage message)
set the in message |
void |
setInterfaceName(QName name)
set an interface |
void |
setMarshaler(PojoMarshaler marshaler)
|
void |
setMessage(javax.jbi.messaging.NormalizedMessage message,
String name)
set a NormalizedMessage with a named reference |
void |
setOperation(QName name)
set an operation |
void |
setOutMessage(javax.jbi.messaging.NormalizedMessage message)
set the out message |
void |
setPersistent(Boolean persistent)
|
void |
setProperty(String name,
Object value)
set a named property on the exchange |
void |
setPushDeliver(boolean b)
|
void |
setService(QName name)
set a service |
void |
setSourceContext(ComponentContextImpl sourceContext)
Set the context |
void |
setSourceId(ComponentNameSpace sourceId)
|
void |
setStatus(javax.jbi.messaging.ExchangeStatus exchangeStatus)
set the processing status |
void |
setSyncState(int syncState)
|
void |
setTransactionContext(Transaction transaction)
set the transaction |
void |
setTxLock(Object txLock)
|
void |
setTxState(int txState)
|
String |
toString()
|
void |
writeExternal(ObjectOutput out)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String IN
public static final String OUT
public static final String FAULT
public static final int MAX_MSG_DISPLAY_SIZE
public static final boolean PRESERVE_CONTENT
public static final int SYNC_STATE_ASYNC
public static final int SYNC_STATE_SYNC_SENT
public static final int SYNC_STATE_SYNC_RECEIVED
public static final int TX_STATE_NONE
public static final int TX_STATE_ENLISTED
public static final int TX_STATE_CONVEYED
protected static final int CAN_SET_IN_MSG
protected static final int CAN_SET_OUT_MSG
protected static final int CAN_SET_FAULT_MSG
protected static final int CAN_PROVIDER
protected static final int CAN_CONSUMER
protected static final int CAN_SEND
protected static final int CAN_STATUS_ACTIVE
protected static final int CAN_STATUS_DONE
protected static final int CAN_STATUS_ERROR
protected static final int CAN_OWNER
protected static final int STATES_CANS
protected static final int STATES_NEXT_OUT
protected static final int STATES_NEXT_FAULT
protected static final int STATES_NEXT_ERROR
protected static final int STATES_NEXT_DONE
protected ComponentContextImpl sourceContext
protected ExchangePacket packet
protected PojoMarshaler marshaler
protected int state
protected int syncState
protected int txState
protected int[][] states
protected MessageExchangeImpl mirror
protected transient boolean pushDeliver
protected transient Object txLock
protected transient String key
| Constructor Detail |
|---|
public MessageExchangeImpl(String exchangeId,
URI pattern,
int[][] states)
exchangeId - pattern -
protected MessageExchangeImpl(ExchangePacket packet,
int[][] states)
protected MessageExchangeImpl()
| Method Detail |
|---|
protected void copyFrom(MessageExchangeImpl me)
protected boolean can(int c)
public ActivationSpec getActivationSpec()
public ComponentContextImpl getSourceContext()
public void setSourceContext(ComponentContextImpl sourceContext)
sourceContext - public ExchangePacket getPacket()
public URI getPattern()
getPattern in interface javax.jbi.messaging.MessageExchangepublic String getExchangeId()
getExchangeId in interface javax.jbi.messaging.MessageExchangepublic javax.jbi.messaging.ExchangeStatus getStatus()
getStatus in interface javax.jbi.messaging.MessageExchange
public void setStatus(javax.jbi.messaging.ExchangeStatus exchangeStatus)
throws javax.jbi.messaging.MessagingException
setStatus in interface javax.jbi.messaging.MessageExchangeexchangeStatus -
javax.jbi.messaging.MessagingExceptionpublic void setError(Exception exception)
setError in interface javax.jbi.messaging.MessageExchangeexception - public Exception getError()
getError in interface javax.jbi.messaging.MessageExchangepublic javax.jbi.messaging.Fault getFault()
getFault in interface javax.jbi.messaging.MessageExchange
public void setFault(javax.jbi.messaging.Fault fault)
throws javax.jbi.messaging.MessagingException
setFault in interface javax.jbi.messaging.MessageExchangefault -
javax.jbi.messaging.MessagingException
public javax.jbi.messaging.NormalizedMessage createMessage()
throws javax.jbi.messaging.MessagingException
createMessage in interface javax.jbi.messaging.MessageExchangejavax.jbi.messaging.MessagingException
public javax.jbi.messaging.Fault createFault()
throws javax.jbi.messaging.MessagingException
createFault in interface javax.jbi.messaging.MessageExchangejavax.jbi.messaging.MessagingExceptionpublic javax.jbi.messaging.NormalizedMessage getMessage(String name)
getMessage in interface javax.jbi.messaging.MessageExchangename -
public void setMessage(javax.jbi.messaging.NormalizedMessage message,
String name)
throws javax.jbi.messaging.MessagingException
setMessage in interface javax.jbi.messaging.MessageExchangemessage - name -
javax.jbi.messaging.MessagingExceptionpublic Object getProperty(String name)
getProperty in interface javax.jbi.messaging.MessageExchangename -
public void setProperty(String name,
Object value)
setProperty in interface javax.jbi.messaging.MessageExchangename - value - public Set getPropertyNames()
getPropertyNames in interface javax.jbi.messaging.MessageExchangepublic void setEndpoint(javax.jbi.servicedesc.ServiceEndpoint endpoint)
setEndpoint in interface javax.jbi.messaging.MessageExchangeendpoint - public void setService(QName name)
setService in interface javax.jbi.messaging.MessageExchangename - public void setOperation(QName name)
setOperation in interface javax.jbi.messaging.MessageExchangename - public void setInterfaceName(QName name)
setInterfaceName in interface javax.jbi.messaging.MessageExchangename - public javax.jbi.servicedesc.ServiceEndpoint getEndpoint()
getEndpoint in interface javax.jbi.messaging.MessageExchangepublic QName getService()
getService in interface javax.jbi.messaging.MessageExchangepublic QName getInterfaceName()
getInterfaceName in interface javax.jbi.messaging.MessageExchangepublic QName getOperation()
getOperation in interface javax.jbi.messaging.MessageExchangepublic Transaction getTransactionContext()
public void setTransactionContext(Transaction transaction)
throws javax.jbi.messaging.MessagingException
transaction -
javax.jbi.messaging.MessagingExceptionpublic boolean isTransacted()
isTransacted in interface javax.jbi.messaging.MessageExchangepublic javax.jbi.messaging.MessageExchange.Role getRole()
getRole in interface javax.jbi.messaging.MessageExchangepublic javax.jbi.messaging.NormalizedMessage getInMessage()
public void setInMessage(javax.jbi.messaging.NormalizedMessage message)
throws javax.jbi.messaging.MessagingException
message -
javax.jbi.messaging.MessagingExceptionpublic javax.jbi.messaging.NormalizedMessage getOutMessage()
public void setOutMessage(javax.jbi.messaging.NormalizedMessage message)
throws javax.jbi.messaging.MessagingException
message -
javax.jbi.messaging.MessagingExceptionpublic ComponentNameSpace getSourceId()
public void setSourceId(ComponentNameSpace sourceId)
sourceId - The sourceId to set.public ComponentNameSpace getDestinationId()
public void setDestinationId(ComponentNameSpace destinationId)
destinationId - The destinationId to set.public Boolean getPersistent()
public void setPersistent(Boolean persistent)
public PojoMarshaler getMarshaler()
public void setMarshaler(PojoMarshaler marshaler)
public abstract void readExternal(ObjectInput in)
throws IOException,
ClassNotFoundException
readExternal in interface ExternalizableIOException
ClassNotFoundException
public void writeExternal(ObjectOutput out)
throws IOException
writeExternal in interface ExternalizableIOException
public void handleSend(boolean sync)
throws javax.jbi.messaging.MessagingException
javax.jbi.messaging.MessagingException
public void handleAccept()
throws javax.jbi.messaging.MessagingException
javax.jbi.messaging.MessagingExceptionpublic MessageExchangeImpl getMirror()
public int getSyncState()
public void setSyncState(int syncState)
public int getTxState()
public void setTxState(int txState)
txState - the txState to setpublic boolean isPushDelivery()
public void setPushDeliver(boolean b)
public Object getTxLock()
public void setTxLock(Object txLock)
txLock - the txLock to setpublic String toString()
toString in class Objectpublic String getKey()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||