org.apache.qpid.framing.amqp_0_9
Class MessageTransferBodyImpl

java.lang.Object
  extended by org.apache.qpid.framing.AMQMethodBodyImpl
      extended by org.apache.qpid.framing.amqp_0_9.AMQMethodBody_0_9
          extended by org.apache.qpid.framing.amqp_0_9.MessageTransferBodyImpl
All Implemented Interfaces:
AMQBody, AMQMethodBody, EncodableAMQDataBlock, MessageTransferBody

public class MessageTransferBodyImpl
extends AMQMethodBody_0_9
implements MessageTransferBody


Field Summary
static int CLASS_ID
           
static int METHOD_ID
           
 
Fields inherited from class org.apache.qpid.framing.AMQMethodBodyImpl
TYPE
 
Fields inherited from interface org.apache.qpid.framing.AMQMethodBody
TYPE
 
Constructor Summary
MessageTransferBodyImpl(org.apache.mina.common.ByteBuffer buffer)
           
MessageTransferBodyImpl(int ticket, AMQShortString destination, boolean redelivered, boolean immediate, long ttl, short priority, long timestamp, short deliveryMode, long expiration, AMQShortString exchange, AMQShortString routingKey, AMQShortString messageId, AMQShortString correlationId, AMQShortString replyTo, AMQShortString contentType, AMQShortString contentEncoding, AMQShortString userId, AMQShortString appId, AMQShortString transactionId, byte[] securityToken, FieldTable applicationHeaders, Content body)
           
 
Method Summary
 boolean execute(MethodDispatcher dispatcher, int channelId)
           
 AMQShortString getAppId()
           
 FieldTable getApplicationHeaders()
           
 Content getBody()
           
protected  int getBodySize()
          unsigned short
 int getClazz()
           
 AMQShortString getContentEncoding()
           
 AMQShortString getContentType()
           
 AMQShortString getCorrelationId()
           
 short getDeliveryMode()
           
 AMQShortString getDestination()
           
 AMQShortString getExchange()
           
 long getExpiration()
           
static AMQMethodBodyInstanceFactory getFactory()
           
 boolean getImmediate()
           
 AMQShortString getMessageId()
           
 int getMethod()
           
 short getPriority()
           
 boolean getRedelivered()
           
 AMQShortString getReplyTo()
           
 AMQShortString getRoutingKey()
           
 byte[] getSecurityToken()
           
 int getTicket()
           
 long getTimestamp()
           
 AMQShortString getTransactionId()
           
 long getTtl()
           
 AMQShortString getUserId()
           
 String toString()
           
 void writeMethodPayload(org.apache.mina.common.ByteBuffer buffer)
           
 
Methods inherited from class org.apache.qpid.framing.amqp_0_9.AMQMethodBody_0_9
getMajor, getMinor
 
Methods inherited from class org.apache.qpid.framing.AMQMethodBodyImpl
generateFrame, getChannelException, getChannelException, getChannelNotFoundException, getConnectionException, getConnectionException, getFrameType, getSize, getSizeOf, getSizeOf, getSizeOf, getSizeOf, handle, readAMQShortString, readBitfield, readByte, readBytes, readContent, readFieldTable, readInt, readLong, readShort, readTimestamp, readUnsignedByte, readUnsignedInteger, readUnsignedShort, writeAMQShortString, writeBitfield, writeByte, writeBytes, writeContent, writeFieldTable, writeInt, writeLong, writePayload, writeShort, writeTimestamp, writeUnsignedByte, writeUnsignedInteger, writeUnsignedShort
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.apache.qpid.framing.AMQMethodBody
generateFrame, getChannelException, getChannelException, getChannelNotFoundException, getConnectionException, getConnectionException, getMajor, getMinor, getSize, writePayload
 
Methods inherited from interface org.apache.qpid.framing.AMQBody
getFrameType, handle
 

Field Detail

CLASS_ID

public static final int CLASS_ID
See Also:
Constant Field Values

METHOD_ID

public static final int METHOD_ID
See Also:
Constant Field Values
Constructor Detail

MessageTransferBodyImpl

public MessageTransferBodyImpl(org.apache.mina.common.ByteBuffer buffer)
                        throws AMQFrameDecodingException
Throws:
AMQFrameDecodingException

MessageTransferBodyImpl

public MessageTransferBodyImpl(int ticket,
                               AMQShortString destination,
                               boolean redelivered,
                               boolean immediate,
                               long ttl,
                               short priority,
                               long timestamp,
                               short deliveryMode,
                               long expiration,
                               AMQShortString exchange,
                               AMQShortString routingKey,
                               AMQShortString messageId,
                               AMQShortString correlationId,
                               AMQShortString replyTo,
                               AMQShortString contentType,
                               AMQShortString contentEncoding,
                               AMQShortString userId,
                               AMQShortString appId,
                               AMQShortString transactionId,
                               byte[] securityToken,
                               FieldTable applicationHeaders,
                               Content body)
Method Detail

getFactory

public static AMQMethodBodyInstanceFactory getFactory()

getClazz

public int getClazz()
Specified by:
getClazz in interface AMQMethodBody
Returns:
unsigned short

getMethod

public int getMethod()
Specified by:
getMethod in interface AMQMethodBody
Returns:
unsigned short

getTicket

public final int getTicket()
Specified by:
getTicket in interface MessageTransferBody

getDestination

public final AMQShortString getDestination()
Specified by:
getDestination in interface MessageTransferBody

getRedelivered

public final boolean getRedelivered()
Specified by:
getRedelivered in interface MessageTransferBody

getImmediate

public final boolean getImmediate()
Specified by:
getImmediate in interface MessageTransferBody

getTtl

public final long getTtl()
Specified by:
getTtl in interface MessageTransferBody

getPriority

public final short getPriority()
Specified by:
getPriority in interface MessageTransferBody

getTimestamp

public final long getTimestamp()
Specified by:
getTimestamp in interface MessageTransferBody

getDeliveryMode

public final short getDeliveryMode()
Specified by:
getDeliveryMode in interface MessageTransferBody

getExpiration

public final long getExpiration()
Specified by:
getExpiration in interface MessageTransferBody

getExchange

public final AMQShortString getExchange()
Specified by:
getExchange in interface MessageTransferBody

getRoutingKey

public final AMQShortString getRoutingKey()
Specified by:
getRoutingKey in interface MessageTransferBody

getMessageId

public final AMQShortString getMessageId()
Specified by:
getMessageId in interface MessageTransferBody

getCorrelationId

public final AMQShortString getCorrelationId()
Specified by:
getCorrelationId in interface MessageTransferBody

getReplyTo

public final AMQShortString getReplyTo()
Specified by:
getReplyTo in interface MessageTransferBody

getContentType

public final AMQShortString getContentType()
Specified by:
getContentType in interface MessageTransferBody

getContentEncoding

public final AMQShortString getContentEncoding()
Specified by:
getContentEncoding in interface MessageTransferBody

getUserId

public final AMQShortString getUserId()
Specified by:
getUserId in interface MessageTransferBody

getAppId

public final AMQShortString getAppId()
Specified by:
getAppId in interface MessageTransferBody

getTransactionId

public final AMQShortString getTransactionId()
Specified by:
getTransactionId in interface MessageTransferBody

getSecurityToken

public final byte[] getSecurityToken()
Specified by:
getSecurityToken in interface MessageTransferBody

getApplicationHeaders

public final FieldTable getApplicationHeaders()
Specified by:
getApplicationHeaders in interface MessageTransferBody

getBody

public final Content getBody()
Specified by:
getBody in interface MessageTransferBody

getBodySize

protected int getBodySize()
Description copied from class: AMQMethodBodyImpl
unsigned short

Specified by:
getBodySize in class AMQMethodBodyImpl

writeMethodPayload

public void writeMethodPayload(org.apache.mina.common.ByteBuffer buffer)
Specified by:
writeMethodPayload in interface AMQMethodBody

execute

public boolean execute(MethodDispatcher dispatcher,
                       int channelId)
                throws AMQException
Specified by:
execute in interface AMQMethodBody
Throws:
AMQException

toString

public String toString()
Specified by:
toString in interface AMQMethodBody
Overrides:
toString in class Object


Licensed to the Apache Software Foundation