Class ProtobufValueWrapper
- java.lang.Object
-
- org.infinispan.query.remote.impl.indexing.ProtobufValueWrapper
-
- All Implemented Interfaces:
org.infinispan.commons.marshall.WrappedBytes
@ProtoTypeId(11) public final class ProtobufValueWrapper extends Object implements org.infinispan.commons.marshall.WrappedBytes
This is used to wrap binary values encoded with Protocol Buffers.ProtobufMessageBridgeis used as a class bridge to allow indexing of the binary payload.- Since:
- 6.0
- Author:
- anistor@redhat.com
-
-
Constructor Summary
Constructors Constructor Description ProtobufValueWrapper(byte[] binary)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intbackArrayOffset()booleanequals(Object o)booleanequalsWrappedBytes(org.infinispan.commons.marshall.WrappedBytes other)byte[]getBinary()Gets the internal byte array.bytegetByte(int offset)byte[]getBytes()intgetLength()org.infinispan.protostream.descriptors.DescriptorgetMessageDescriptor()Returns the Protobuf descriptor of the message type of the payload.inthashCode()StringtoString()
-
-
-
Method Detail
-
getBinary
@ProtoField(number=1) public byte[] getBinary()
Gets the internal byte array. Callers should not modify the contents of the array.- Returns:
- the wrapped byte array
-
getMessageDescriptor
public org.infinispan.protostream.descriptors.Descriptor getMessageDescriptor()
Returns the Protobuf descriptor of the message type of the payload.
-
getBytes
public byte[] getBytes()
- Specified by:
getBytesin interfaceorg.infinispan.commons.marshall.WrappedBytes
-
backArrayOffset
public int backArrayOffset()
- Specified by:
backArrayOffsetin interfaceorg.infinispan.commons.marshall.WrappedBytes
-
getLength
public int getLength()
- Specified by:
getLengthin interfaceorg.infinispan.commons.marshall.WrappedBytes
-
getByte
public byte getByte(int offset)
- Specified by:
getBytein interfaceorg.infinispan.commons.marshall.WrappedBytes
-
equalsWrappedBytes
public boolean equalsWrappedBytes(org.infinispan.commons.marshall.WrappedBytes other)
- Specified by:
equalsWrappedBytesin interfaceorg.infinispan.commons.marshall.WrappedBytes
-
-