Package org.infinispan.protostream.impl
Class MessageMarshallerDelegate<T>
java.lang.Object
org.infinispan.protostream.impl.BaseMarshallerDelegate<T>
org.infinispan.protostream.impl.MessageMarshallerDelegate<T>
- Since:
- 1.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final FieldDescriptor[]private static final UnknownFieldSetHandler<Message> private final MessageMarshaller<T> private final Descriptorprivate final UnknownFieldSetHandler<T> -
Constructor Summary
ConstructorsConstructorDescriptionMessageMarshallerDelegate(MessageMarshaller<T> marshaller, Descriptor messageDescriptor) -
Method Summary
Modifier and TypeMethodDescriptionGets the wrapped marshaller.voidmarshall(ProtobufTagMarshaller.WriteContext ctx, FieldDescriptor fieldDescriptor, T message) Marshalls an object.unmarshall(ProtobufTagMarshaller.ReadContext ctx, FieldDescriptor fieldDescriptor) Unmarshalls an object.
-
Field Details
-
marshaller
-
messageDescriptor
-
fieldDescriptors
-
unknownFieldSetHandler
-
legacyUnknownFieldSetHandler
-
-
Constructor Details
-
MessageMarshallerDelegate
MessageMarshallerDelegate(MessageMarshaller<T> marshaller, Descriptor messageDescriptor)
-
-
Method Details
-
getMarshaller
Description copied from class:BaseMarshallerDelegateGets the wrapped marshaller.- Specified by:
getMarshallerin classBaseMarshallerDelegate<T>- Returns:
- the wrapped marshaller instance
-
marshall
public void marshall(ProtobufTagMarshaller.WriteContext ctx, FieldDescriptor fieldDescriptor, T message) throws IOException Description copied from class:BaseMarshallerDelegateMarshalls an object.- Specified by:
marshallin classBaseMarshallerDelegate<T>- Parameters:
ctx- operation contextfieldDescriptor- theFieldDescriptorof the field being marshalled ornullif this is a top-level objectmessage- the value being marshalled (cannot benull)- Throws:
IOException- if marshalling fails for some reason
-
unmarshall
public T unmarshall(ProtobufTagMarshaller.ReadContext ctx, FieldDescriptor fieldDescriptor) throws IOException Description copied from class:BaseMarshallerDelegateUnmarshalls an object.- Specified by:
unmarshallin classBaseMarshallerDelegate<T>- Parameters:
ctx- operation contextfieldDescriptor- theFieldDescriptorof the field being unmarshalled ornullif this is a top-level object- Throws:
IOException- if unmarshalling fails for some reason
-