Class SizeComputingProtoStreamWriter
java.lang.Object
org.wildfly.clustering.marshalling.protostream.AbstractProtoStreamOperation
org.wildfly.clustering.marshalling.protostream.AbstractProtoStreamWriter
org.wildfly.clustering.marshalling.protostream.SizeComputingProtoStreamWriter
- All Implemented Interfaces:
Function<Object,,OptionalInt> Supplier<OptionalInt>,org.infinispan.protostream.ProtobufTagMarshaller.OperationContext,org.infinispan.protostream.ProtobufTagMarshaller.WriteContext,org.infinispan.protostream.RawProtoStreamWriter,org.infinispan.protostream.TagWriter,ProtoStreamOperation,ProtoStreamWriter
public class SizeComputingProtoStreamWriter
extends AbstractProtoStreamWriter
implements Supplier<OptionalInt>, Function<Object,OptionalInt>
A
ProtoStreamWriter implementation used to compute the number of bytes that would be written to a stream.- Author:
- Paul Ferraro
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.wildfly.clustering.marshalling.protostream.ProtoStreamOperation
ProtoStreamOperation.Context -
Method Summary
Modifier and TypeMethodDescriptionget()Returns the context of this operationvoidwriteObjectNoTag(Object value) Writes the specified object of a specific type.Methods inherited from class org.wildfly.clustering.marshalling.protostream.AbstractProtoStreamWriter
createFieldSetWriter, depth, flush, getWriter, writeAnyNoTag, writeBool, writeBytes, writeBytes, writeBytes, writeDouble, writeEnum, writeFixed32, writeFixed64, writeFloat, writeInt32, writeInt64, writeRawByte, writeRawBytes, writeRawBytes, writeSFixed32, writeSFixed64, writeSInt32, writeSInt64, writeString, writeTag, writeUInt32, writeUInt64, writeVarint32, writeVarint64Methods inherited from class org.wildfly.clustering.marshalling.protostream.AbstractProtoStreamOperation
getParam, getSerializationContext, setParamMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.infinispan.protostream.ProtobufTagMarshaller.OperationContext
getParam, getSerializationContext, setParamMethods inherited from interface org.wildfly.clustering.marshalling.protostream.ProtoStreamOperation
findMarshaller, getSerializationContextMethods inherited from interface org.wildfly.clustering.marshalling.protostream.ProtoStreamWriter
writeAny, writeEnum, writeObject, writeTagMethods inherited from interface org.infinispan.protostream.RawProtoStreamWriter
writeUInt32NoTag, writeUInt64NoTag
-
Method Details
-
getContext
Description copied from interface:ProtoStreamOperationReturns the context of this operation- Specified by:
getContextin interfaceProtoStreamOperation- Overrides:
getContextin classAbstractProtoStreamWriter- Returns:
- the operation context
-
get
- Specified by:
getin interfaceSupplier<OptionalInt>
-
writeObjectNoTag
Description copied from interface:ProtoStreamWriterWrites the specified object of a specific type. Must be preceded by {TagWriter.writeTag(int, org.infinispan.protostream.descriptors.WireType).- Specified by:
writeObjectNoTagin interfaceProtoStreamWriter- Parameters:
value- a value to be written- Throws:
IOException- if no marshaller is associated with the type of the specified object, or if the marshaller fails to write the specified object
-
apply
- Specified by:
applyin interfaceFunction<Object,OptionalInt>
-