Class JBossByteBufferMarshaller

java.lang.Object
org.wildfly.clustering.marshalling.AbstractByteBufferMarshaller
org.wildfly.clustering.marshalling.jboss.JBossByteBufferMarshaller
All Implemented Interfaces:
Predicate<Object>, Predicate<Object>, ByteBufferMarshaller, Marshaller<Object, ByteBuffer>

public class JBossByteBufferMarshaller extends AbstractByteBufferMarshaller
A ByteBufferMarshaller based on JBoss Marshalling.
Author:
Paul Ferraro
  • Constructor Details

    • JBossByteBufferMarshaller

      public JBossByteBufferMarshaller(MarshallingConfigurationRepository repository, ClassLoader loader)
      Creates a versioned marshaller supporting multiple marshalling configurations.
      Parameters:
      repository - a repository of marshalling configurations
      loader - a class loader
    • JBossByteBufferMarshaller

      public JBossByteBufferMarshaller(org.jboss.marshalling.MarshallingConfiguration configuration, ClassLoader loader)
      Creates an unversioned marshaller using a single marshalling configuration.
      Parameters:
      configuration - a marshalling configuration
      loader - a loader
  • Method Details

    • readFrom

      public Object readFrom(InputStream input) throws IOException
      Description copied from interface: ByteBufferMarshaller
      Reads an object from the specified input stream.
      Parameters:
      input - an input stream
      Returns:
      the unmarshalled object
      Throws:
      IOException - if the object could not be read
    • writeTo

      public void writeTo(OutputStream output, Object value) throws IOException
      Description copied from interface: ByteBufferMarshaller
      Writes the specified object to the specified output stream.
      Parameters:
      output - an output stream
      value - an object to marshal
      Throws:
      IOException - if the object could not be written
    • test

      public boolean test(Object object)
    • toString

      public String toString()
      Overrides:
      toString in class Object