Class MarshallerUtil

java.lang.Object
org.infinispan.client.hotrod.marshall.MarshallerUtil

public final class MarshallerUtil extends Object
Author:
Galder ZamarreƱo
  • Method Details

    • getSerializationContext

      public static org.infinispan.protostream.SerializationContext getSerializationContext(RemoteCacheContainer remoteCacheManager)
      A convenience method to return the SerializationContext associated with the ProtoStreamMarshaller configured on the provided RemoteCacheManager.
      Returns:
      the associated SerializationContext
      Throws:
      HotRodClientException - if the cache manager is not started or is not configured to use a ProtoStreamMarshaller
    • bytes2obj

      public static <T> T bytes2obj(Marshaller marshaller, byte[] bytes, boolean objectStorage, ClassAllowList allowList)
    • tryJavaDeserialize

      public static <T> T tryJavaDeserialize(byte[] bytes, byte[] ret, ClassAllowList allowList)
    • obj2bytes

      @Deprecated(forRemoval=true) public static byte[] obj2bytes(Marshaller marshaller, Object o, boolean isKey, int estimateKeySize, int estimateValueSize)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Since 12.0, will be removed in 15.0
    • obj2bytes

      public static byte[] obj2bytes(Marshaller marshaller, Object o, BufferSizePredictor sizePredictor)