Class NettyReadable
- java.lang.Object
-
- org.apache.activemq.artemis.protocol.amqp.util.NettyReadable
-
- All Implemented Interfaces:
org.apache.qpid.proton.codec.ReadableBuffer
public class NettyReadable extends java.lang.Object implements org.apache.qpid.proton.codec.ReadableBufferReadableBufferimplementation that wraps a NettyByteBufto allow use of Netty buffers to be used when decoding AMQP messages.
-
-
Constructor Summary
Constructors Constructor Description NettyReadable(io.netty.buffer.ByteBuf buffer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]array()intarrayOffset()java.nio.ByteBufferbyteBuffer()intcapacity()org.apache.qpid.proton.codec.ReadableBufferclear()org.apache.qpid.proton.codec.ReadableBufferduplicate()booleanequals(java.lang.Object other)org.apache.qpid.proton.codec.ReadableBufferflip()byteget()org.apache.qpid.proton.codec.ReadableBufferget(byte[] data)org.apache.qpid.proton.codec.ReadableBufferget(byte[] data, int offset, int length)byteget(int index)org.apache.qpid.proton.codec.ReadableBufferget(org.apache.qpid.proton.codec.WritableBuffer target)io.netty.buffer.ByteBufgetByteBuf()doublegetDouble()floatgetFloat()intgetInt()longgetLong()shortgetShort()booleanhasArray()inthashCode()booleanhasRemaining()intlimit()org.apache.qpid.proton.codec.ReadableBufferlimit(int limit)org.apache.qpid.proton.codec.ReadableBuffermark()intposition()org.apache.qpid.proton.codec.ReadableBufferposition(int position)java.lang.StringreadString(java.nio.charset.CharsetDecoder decoder)java.lang.StringreadUTF8()org.apache.qpid.proton.codec.ReadableBufferreclaimRead()intremaining()org.apache.qpid.proton.codec.ReadableBufferreset()org.apache.qpid.proton.codec.ReadableBufferrewind()org.apache.qpid.proton.codec.ReadableBufferslice()java.lang.StringtoString()
-
-
-
Method Detail
-
getByteBuf
public io.netty.buffer.ByteBuf getByteBuf()
-
get
public byte get()
- Specified by:
getin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
getInt
public int getInt()
- Specified by:
getIntin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
getLong
public long getLong()
- Specified by:
getLongin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
getShort
public short getShort()
- Specified by:
getShortin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
getFloat
public float getFloat()
- Specified by:
getFloatin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
getDouble
public double getDouble()
- Specified by:
getDoublein interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
get
public org.apache.qpid.proton.codec.ReadableBuffer get(byte[] data, int offset, int length)- Specified by:
getin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
get
public org.apache.qpid.proton.codec.ReadableBuffer get(byte[] data)
- Specified by:
getin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
position
public org.apache.qpid.proton.codec.ReadableBuffer position(int position)
- Specified by:
positionin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
slice
public org.apache.qpid.proton.codec.ReadableBuffer slice()
- Specified by:
slicein interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
flip
public org.apache.qpid.proton.codec.ReadableBuffer flip()
- Specified by:
flipin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
limit
public org.apache.qpid.proton.codec.ReadableBuffer limit(int limit)
- Specified by:
limitin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
limit
public int limit()
- Specified by:
limitin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
remaining
public int remaining()
- Specified by:
remainingin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
position
public int position()
- Specified by:
positionin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
hasRemaining
public boolean hasRemaining()
- Specified by:
hasRemainingin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
duplicate
public org.apache.qpid.proton.codec.ReadableBuffer duplicate()
- Specified by:
duplicatein interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
byteBuffer
public java.nio.ByteBuffer byteBuffer()
- Specified by:
byteBufferin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
readUTF8
public java.lang.String readUTF8()
- Specified by:
readUTF8in interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
array
public byte[] array()
- Specified by:
arrayin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
arrayOffset
public int arrayOffset()
- Specified by:
arrayOffsetin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
capacity
public int capacity()
- Specified by:
capacityin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
clear
public org.apache.qpid.proton.codec.ReadableBuffer clear()
- Specified by:
clearin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
reclaimRead
public org.apache.qpid.proton.codec.ReadableBuffer reclaimRead()
- Specified by:
reclaimReadin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
get
public byte get(int index)
- Specified by:
getin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
hasArray
public boolean hasArray()
- Specified by:
hasArrayin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
mark
public org.apache.qpid.proton.codec.ReadableBuffer mark()
- Specified by:
markin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
readString
public java.lang.String readString(java.nio.charset.CharsetDecoder decoder) throws java.nio.charset.CharacterCodingException- Specified by:
readStringin interfaceorg.apache.qpid.proton.codec.ReadableBuffer- Throws:
java.nio.charset.CharacterCodingException
-
reset
public org.apache.qpid.proton.codec.ReadableBuffer reset()
- Specified by:
resetin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
rewind
public org.apache.qpid.proton.codec.ReadableBuffer rewind()
- Specified by:
rewindin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
get
public org.apache.qpid.proton.codec.ReadableBuffer get(org.apache.qpid.proton.codec.WritableBuffer target)
- Specified by:
getin interfaceorg.apache.qpid.proton.codec.ReadableBuffer
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object other)
- Overrides:
equalsin classjava.lang.Object
-
-