Class AbstractProtoStreamWriter
- java.lang.Object
-
- org.wildfly.clustering.marshalling.protostream.AbstractProtoStreamOperation
-
- org.wildfly.clustering.marshalling.protostream.AbstractProtoStreamWriter
-
- All Implemented Interfaces:
org.infinispan.protostream.ProtobufTagMarshaller.OperationContext,org.infinispan.protostream.ProtobufTagMarshaller.WriteContext,org.infinispan.protostream.RawProtoStreamWriter,org.infinispan.protostream.TagWriter,ProtoStreamOperation,ProtoStreamWriter
- Direct Known Subclasses:
DefaultProtoStreamWriter,SizeComputingProtoStreamWriter
public abstract class AbstractProtoStreamWriter extends AbstractProtoStreamOperation implements ProtoStreamWriter, org.infinispan.protostream.ProtobufTagMarshaller.WriteContext
Delegates mostProtoStreamWriteroperations to aTagWriter.- Author:
- Paul Ferraro
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.wildfly.clustering.marshalling.protostream.ProtoStreamOperation
ProtoStreamOperation.Context
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractProtoStreamWriter(org.infinispan.protostream.ProtobufTagMarshaller.WriteContext context, org.wildfly.clustering.marshalling.protostream.AbstractProtoStreamWriter.ProtoStreamWriterContext writerContext)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description intdepth()voidflush()ProtoStreamOperation.ContextgetContext()Returns the context of this operationorg.infinispan.protostream.TagWritergetWriter()voidwriteAnyNoTag(Object value)Writes the specified object of an arbitrary type.voidwriteBool(int index, boolean value)voidwriteBytes(int index, byte[] value)voidwriteBytes(int index, byte[] value, int offset, int length)voidwriteBytes(int index, ByteBuffer value)voidwriteDouble(int index, double value)voidwriteEnum(int index, int value)voidwriteFixed32(int index, int value)Deprecated.voidwriteFixed64(int index, long value)Deprecated.voidwriteFloat(int index, float value)voidwriteInt32(int index, int value)Deprecated.voidwriteInt64(int index, long value)Deprecated.voidwriteRawByte(byte value)Deprecated.voidwriteRawBytes(byte[] value, int offset, int length)voidwriteRawBytes(ByteBuffer value)Deprecated.voidwriteSFixed32(int index, int value)voidwriteSFixed64(int index, long value)voidwriteSInt32(int index, int value)voidwriteSInt64(int index, long value)voidwriteString(int index, String value)voidwriteTag(int number, org.infinispan.protostream.descriptors.WireType wireType)voidwriteUInt32(int index, int value)voidwriteUInt64(int index, long value)voidwriteVarint32(int value)voidwriteVarint64(long value)-
Methods inherited from class org.wildfly.clustering.marshalling.protostream.AbstractProtoStreamOperation
getParam, getSerializationContext, setParam
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.infinispan.protostream.ProtobufTagMarshaller.OperationContext
getParam, getSerializationContext, setParam
-
Methods inherited from interface org.wildfly.clustering.marshalling.protostream.ProtoStreamOperation
findMarshaller, getSerializationContext
-
Methods inherited from interface org.wildfly.clustering.marshalling.protostream.ProtoStreamWriter
writeAny, writeEnum, writeObject, writeObjectNoTag, writeTag
-
-
-
-
Method Detail
-
getContext
public ProtoStreamOperation.Context getContext()
Description copied from interface:ProtoStreamOperationReturns the context of this operation- Specified by:
getContextin interfaceProtoStreamOperation- Returns:
- the operation context
-
getWriter
public org.infinispan.protostream.TagWriter getWriter()
- Specified by:
getWriterin interfaceorg.infinispan.protostream.ProtobufTagMarshaller.WriteContext
-
depth
public int depth()
- Specified by:
depthin interfaceorg.infinispan.protostream.ProtobufTagMarshaller.WriteContext
-
writeAnyNoTag
public void writeAnyNoTag(Object value) throws IOException
Description copied from interface:ProtoStreamWriterWrites the specified object of an arbitrary type. Must be preceded by {TagWriter.writeTag(int, org.infinispan.protostream.descriptors.WireType).- Specified by:
writeAnyNoTagin 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
-
writeTag
public void writeTag(int number, org.infinispan.protostream.descriptors.WireType wireType) throws IOException- Specified by:
writeTagin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeTagin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeVarint32
public void writeVarint32(int value) throws IOException- Specified by:
writeVarint32in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeVarint32in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeVarint64
public void writeVarint64(long value) throws IOException- Specified by:
writeVarint64in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeVarint64in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeRawByte
@Deprecated public void writeRawByte(byte value) throws IOException
Deprecated.- Specified by:
writeRawBytein interfaceorg.infinispan.protostream.RawProtoStreamWriter- Throws:
IOException
-
writeRawBytes
public void writeRawBytes(byte[] value, int offset, int length) throws IOException- Specified by:
writeRawBytesin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeRawBytesin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeRawBytes
@Deprecated public void writeRawBytes(ByteBuffer value) throws IOException
Deprecated.- Specified by:
writeRawBytesin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Throws:
IOException
-
writeBool
public void writeBool(int index, boolean value) throws IOException- Specified by:
writeBoolin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeBoolin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeEnum
public void writeEnum(int index, int value) throws IOException- Specified by:
writeEnumin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeEnumin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeInt32
@Deprecated public void writeInt32(int index, int value) throws IOException
Deprecated.Description copied from interface:ProtoStreamWriterDeprecated to discourage use.- Specified by:
writeInt32in interfaceProtoStreamWriter- Specified by:
writeInt32in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeInt32in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeFixed32
@Deprecated public void writeFixed32(int index, int value) throws IOException
Deprecated.Description copied from interface:ProtoStreamWriterDeprecated to discourage use.- Specified by:
writeFixed32in interfaceProtoStreamWriter- Specified by:
writeFixed32in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeFixed32in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeUInt32
public void writeUInt32(int index, int value) throws IOException- Specified by:
writeUInt32in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeUInt32in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeSInt32
public void writeSInt32(int index, int value) throws IOException- Specified by:
writeSInt32in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeSInt32in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeSFixed32
public void writeSFixed32(int index, int value) throws IOException- Specified by:
writeSFixed32in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeSFixed32in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeInt64
@Deprecated public void writeInt64(int index, long value) throws IOException
Deprecated.Description copied from interface:ProtoStreamWriterDeprecated to discourage use.- Specified by:
writeInt64in interfaceProtoStreamWriter- Specified by:
writeInt64in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeInt64in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeFixed64
@Deprecated public void writeFixed64(int index, long value) throws IOException
Deprecated.Description copied from interface:ProtoStreamWriterDeprecated to discourage use.- Specified by:
writeFixed64in interfaceProtoStreamWriter- Specified by:
writeFixed64in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeFixed64in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeUInt64
public void writeUInt64(int index, long value) throws IOException- Specified by:
writeUInt64in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeUInt64in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeSInt64
public void writeSInt64(int index, long value) throws IOException- Specified by:
writeSInt64in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeSInt64in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeSFixed64
public void writeSFixed64(int index, long value) throws IOException- Specified by:
writeSFixed64in interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeSFixed64in interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeFloat
public void writeFloat(int index, float value) throws IOException- Specified by:
writeFloatin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeFloatin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeDouble
public void writeDouble(int index, double value) throws IOException- Specified by:
writeDoublein interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeDoublein interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeBytes
public void writeBytes(int index, byte[] value) throws IOException- Specified by:
writeBytesin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeBytesin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeBytes
public void writeBytes(int index, byte[] value, int offset, int length) throws IOException- Specified by:
writeBytesin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeBytesin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeBytes
public void writeBytes(int index, ByteBuffer value) throws IOException- Specified by:
writeBytesin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeBytesin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
writeString
public void writeString(int index, String value) throws IOException- Specified by:
writeStringin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
writeStringin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
flush
public void flush() throws IOException- Specified by:
flushin interfaceorg.infinispan.protostream.RawProtoStreamWriter- Specified by:
flushin interfaceorg.infinispan.protostream.TagWriter- Throws:
IOException
-
-