com.rabbitmq.client.impl
Class MethodArgumentReader

java.lang.Object
  extended by com.rabbitmq.client.impl.MethodArgumentReader

public class MethodArgumentReader
extends java.lang.Object

Parses AMQP wire-protocol Method arguments from a DataInputStream. Methods on this object are usually called from autogenerated code.


Constructor Summary
MethodArgumentReader(java.io.DataInputStream in)
          Construct a MethodArgumentReader streaming over the given DataInputStream.
 
Method Summary
 boolean readBit()
          Public API - reads a bit/boolean argument.
 int readLong()
          Public API - reads an integer argument.
 long readLonglong()
          Public API - reads a long integer argument.
 LongString readLongstr()
          Public API - reads a long string argument.
static LongString readLongstr(java.io.DataInputStream in)
          Public API - convenience method - reads a long string argument from a DataInputStream.
 int readOctet()
          Public API - reads an octet argument.
 int readShort()
          Public API - reads a short integer argument.
 java.lang.String readShortstr()
          Public API - reads a short string argument.
static java.lang.String readShortstr(java.io.DataInputStream in)
          Public API - convenience method - reads a short string from a DataInputStream.
 java.util.Map<java.lang.String,java.lang.Object> readTable()
          Public API - reads a table argument.
static java.util.Map<java.lang.String,java.lang.Object> readTable(java.io.DataInputStream in)
          Public API - reads a table argument from a given stream.
 java.util.Date readTimestamp()
          Public API - reads an timestamp argument.
static java.util.Date readTimestamp(java.io.DataInputStream in)
          Public API - convenience method - reads a timestamp argument from the DataInputStream.
protected static long unsignedExtend(int value)
          Protected API - Cast an int to a long without extending the sign bit of the int out into the high half of the long.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MethodArgumentReader

public MethodArgumentReader(java.io.DataInputStream in)
Construct a MethodArgumentReader streaming over the given DataInputStream.

Method Detail

unsignedExtend

protected static long unsignedExtend(int value)
Protected API - Cast an int to a long without extending the sign bit of the int out into the high half of the long.


readShortstr

public static final java.lang.String readShortstr(java.io.DataInputStream in)
                                           throws java.io.IOException
Public API - convenience method - reads a short string from a DataInputStream.

Throws:
java.io.IOException

readShortstr

public final java.lang.String readShortstr()
                                    throws java.io.IOException
Public API - reads a short string argument.

Throws:
java.io.IOException

readLongstr

public static final LongString readLongstr(java.io.DataInputStream in)
                                    throws java.io.IOException
Public API - convenience method - reads a long string argument from a DataInputStream.

Throws:
java.io.IOException

readLongstr

public final LongString readLongstr()
                             throws java.io.IOException
Public API - reads a long string argument.

Throws:
java.io.IOException

readShort

public final int readShort()
                    throws java.io.IOException
Public API - reads a short integer argument.

Throws:
java.io.IOException

readLong

public final int readLong()
                   throws java.io.IOException
Public API - reads an integer argument.

Throws:
java.io.IOException

readLonglong

public final long readLonglong()
                        throws java.io.IOException
Public API - reads a long integer argument.

Throws:
java.io.IOException

readBit

public final boolean readBit()
                      throws java.io.IOException
Public API - reads a bit/boolean argument.

Throws:
java.io.IOException

readTable

public final java.util.Map<java.lang.String,java.lang.Object> readTable()
                                                                 throws java.io.IOException
Public API - reads a table argument.

Throws:
java.io.IOException

readTable

public static final java.util.Map<java.lang.String,java.lang.Object> readTable(java.io.DataInputStream in)
                                                                        throws java.io.IOException
Public API - reads a table argument from a given stream. Also called by ContentHeaderPropertyReader.

Throws:
java.io.IOException

readOctet

public final int readOctet()
                    throws java.io.IOException
Public API - reads an octet argument.

Throws:
java.io.IOException

readTimestamp

public static final java.util.Date readTimestamp(java.io.DataInputStream in)
                                          throws java.io.IOException
Public API - convenience method - reads a timestamp argument from the DataInputStream.

Throws:
java.io.IOException

readTimestamp

public final java.util.Date readTimestamp()
                                   throws java.io.IOException
Public API - reads an timestamp argument.

Throws:
java.io.IOException