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. ProtobufMessageBridge is used as a class bridge to allow indexing of the binary payload.
Since:
6.0
Author:
anistor@redhat.com
  • Constructor Details

    • ProtobufValueWrapper

      @ProtoFactory public ProtobufValueWrapper(byte[] binary)
  • Method Details

    • 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.
      See Also:
      • setMessageDescriptor(org.infinispan.protostream.descriptors.Descriptor)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getBytes

      public byte[] getBytes()
      Specified by:
      getBytes in interface org.infinispan.commons.marshall.WrappedBytes
    • backArrayOffset

      public int backArrayOffset()
      Specified by:
      backArrayOffset in interface org.infinispan.commons.marshall.WrappedBytes
    • getLength

      public int getLength()
      Specified by:
      getLength in interface org.infinispan.commons.marshall.WrappedBytes
    • getByte

      public byte getByte(int offset)
      Specified by:
      getByte in interface org.infinispan.commons.marshall.WrappedBytes
    • equalsWrappedBytes

      public boolean equalsWrappedBytes(org.infinispan.commons.marshall.WrappedBytes other)
      Specified by:
      equalsWrappedBytes in interface org.infinispan.commons.marshall.WrappedBytes