VMware VMware GemFire Native .NET Reference 10.4.3
Loading...
Searching...
No Matches
Apache::Geode::Client::DataOutput Class Reference

Provides operations for writing primitive data values, and user-defined objects implementing ISerializable, to a byte stream. More...

#include <DataOutput.hpp>

Public Member Functions

void AdvanceCursor (System::UInt32 offset)
 Advance the buffer cursor by the given offset.
 
 DataOutput (Apache::Geode::Client::Cache^ cache)
 Default constructor.
 
array< Byte > ^ GetBuffer ()
 Get a copy of the current buffer.
 
void Reset ()
 Reset the cursor to the start of the buffer.
 
void RewindCursor (System::UInt32 offset)
 Rewind the buffer cursor by the given offset.
 
void WriteArrayLen (System::Int32 len)
 Write length of the array to the DataOutput.
 
void WriteArrayOfByteArrays (array< array< Byte >^>^ value)
 Write a array of sign byte array to the DataOutput.
 
void WriteBoolean (bool value)
 Write a boolean value to the DataOutput.
 
void WriteBooleanArray (array< bool >^ value)
 Write a bool array to the DataOutput.
 
void WriteBytes (array< Byte >^ bytes)
 Write an array of bytes to the DataOutput.
 
void WriteBytes (array< Byte >^ bytes, System::Int32 len)
 Write a given length of bytes to the DataOutput.
 
void WriteBytesOnly (array< Byte >^ bytes)
 Write an array of bytes without its length to the DataOutput.
 
void WriteBytesOnly (array< Byte >^ bytes, System::UInt32 len)
 Write a given length of bytes without its length to the DataOutput.
 
void WriteChar (Char value)
 Write a char value to the DataOutput.
 
void WriteCharArray (array< Char >^ value)
 Write a char array to the DataOutput.
 
void WriteCollection (System::Collections::IList^ value)
 Write a collection to the DataOutput.
 
void WriteDate (System::DateTime value)
 Write a date to the DataOutput.
 
void WriteDictionary (System::Collections::IDictionary^ value)
 Write a Dictionary to the DataOutput.
 
void WriteDouble (double value)
 Write a double precision real number to the DataOutput.
 
void WriteDoubleArray (array< double >^ value)
 Write a double array to the DataOutput.
 
void WriteFloat (float value)
 Write a float to the DataOutput.
 
void WriteFloatArray (array< float >^ value)
 Write a float array to the DataOutput.
 
void WriteInt16 (System::Int16 value)
 Write a 16-bit integer to the DataOutput.
 
void WriteInt32 (System::Int32 value)
 Write a 32-bit integer to the DataOutput.
 
void WriteInt64 (System::Int64 value)
 Write a 64-bit integer to the DataOutput.
 
void WriteIntArray (array< Int32 >^ value)
 Write a int array to the DataOutput.
 
void WriteLongArray (array< Int64 >^ value)
 Write a long array to the DataOutput.
 
void WriteObject (Object^ obj)
 Write a Serializable object to the DataOutput.
 
void WriteObjectArray (List< Object^>^ value)
 Write a object array to the DataOutput.
 
void WriteSByte (SByte value)
 Write a signed byte to the DataOutput.
 
void WriteSBytes (array< SByte >^ bytes)
 Write an array of signed bytes to the DataOutput.
 
void WriteSBytes (array< SByte >^ bytes, System::Int32 len)
 Write a given length of signed bytes to the DataOutput.
 
void WriteSBytesOnly (array< SByte >^ bytes)
 Write an array of signed bytes without its length to the DataOutput.
 
void WriteSBytesOnly (array< SByte >^ bytes, System::UInt32 len)
 Write a given length of signed bytes without its length to the DataOutput.
 
void WriteShortArray (array< Int16 >^ value)
 Write a short array to the DataOutput.
 
void WriteUTF (String^ value)
 Write a string using java-modified UTF-8 encoding to DataOutput.
 

Properties

size_t BufferLength [get]
 Get the length of current data in the buffer.
 

Detailed Description

Provides operations for writing primitive data values, and user-defined objects implementing ISerializable, to a byte stream.

This class is intentionally not thread safe.

Constructor & Destructor Documentation

◆ DataOutput()

Apache::Geode::Client::DataOutput::DataOutput ( Apache::Geode::Client::Cache cache)

Default constructor.

Member Function Documentation

◆ AdvanceCursor()

void Apache::Geode::Client::DataOutput::AdvanceCursor ( System::UInt32  offset)

Advance the buffer cursor by the given offset.

Parameters
offsetThe offset by which to advance the cursor.

◆ GetBuffer()

array< Byte > ^ Apache::Geode::Client::DataOutput::GetBuffer ( )

Get a copy of the current buffer.

◆ Reset()

void Apache::Geode::Client::DataOutput::Reset ( )

Reset the cursor to the start of the buffer.

◆ RewindCursor()

void Apache::Geode::Client::DataOutput::RewindCursor ( System::UInt32  offset)

Rewind the buffer cursor by the given offset.

Parameters
offsetThe offset by which to rewind the cursor.

◆ WriteArrayLen()

void Apache::Geode::Client::DataOutput::WriteArrayLen ( System::Int32  len)

Write length of the array to the DataOutput.

Parameters
lenArray len to write.

◆ WriteArrayOfByteArrays()

void Apache::Geode::Client::DataOutput::WriteArrayOfByteArrays ( array< array< Byte >^>^  value)

Write a array of sign byte array to the DataOutput.

Parameters
valueThe array of sign byte array to write.

◆ WriteBoolean()

void Apache::Geode::Client::DataOutput::WriteBoolean ( bool  value)

Write a boolean value to the DataOutput.

Parameters
valueThe boolean value to write.

◆ WriteBooleanArray()

void Apache::Geode::Client::DataOutput::WriteBooleanArray ( array< bool >^  value)

Write a bool array to the DataOutput.

Parameters
valueThe bool array to write.

◆ WriteBytes() [1/2]

void Apache::Geode::Client::DataOutput::WriteBytes ( array< Byte >^  bytes)
inline

Write an array of bytes to the DataOutput.

Parameters
bytesThe array of bytes to write.

◆ WriteBytes() [2/2]

void Apache::Geode::Client::DataOutput::WriteBytes ( array< Byte >^  bytes,
System::Int32  len 
)

Write a given length of bytes to the DataOutput.

Parameters
bytesThe array of bytes to write.
lenThe number of bytes from the start of array to write.

◆ WriteBytesOnly() [1/2]

void Apache::Geode::Client::DataOutput::WriteBytesOnly ( array< Byte >^  bytes)
inline

Write an array of bytes without its length to the DataOutput.

Parameters
bytesThe array of bytes to write.

◆ WriteBytesOnly() [2/2]

void Apache::Geode::Client::DataOutput::WriteBytesOnly ( array< Byte >^  bytes,
System::UInt32  len 
)

Write a given length of bytes without its length to the DataOutput.

Parameters
bytesThe array of bytes to write.
lenThe number of bytes from the start of array to write.

◆ WriteChar()

void Apache::Geode::Client::DataOutput::WriteChar ( Char  value)

Write a char value to the DataOutput.

Parameters
valueThe char value to write.

◆ WriteCharArray()

void Apache::Geode::Client::DataOutput::WriteCharArray ( array< Char >^  value)

Write a char array to the DataOutput.

Parameters
valueThe char array to write.

◆ WriteCollection()

void Apache::Geode::Client::DataOutput::WriteCollection ( System::Collections::IList^  value)

Write a collection to the DataOutput.

Parameters
valueThe object which implements IList to write.

◆ WriteDate()

void Apache::Geode::Client::DataOutput::WriteDate ( System::DateTime  value)

Write a date to the DataOutput.

Parameters
valueThe date value to write.

◆ WriteDictionary()

void Apache::Geode::Client::DataOutput::WriteDictionary ( System::Collections::IDictionary^  value)

Write a Dictionary to the DataOutput.

Parameters
valueThe object which implements IDictionary to write.

◆ WriteDouble()

void Apache::Geode::Client::DataOutput::WriteDouble ( double  value)

Write a double precision real number to the DataOutput.

Parameters
valueThe double precision real number to write.

◆ WriteDoubleArray()

void Apache::Geode::Client::DataOutput::WriteDoubleArray ( array< double >^  value)

Write a double array to the DataOutput.

Parameters
valueThe double array to write.

◆ WriteFloat()

void Apache::Geode::Client::DataOutput::WriteFloat ( float  value)

Write a float to the DataOutput.

Parameters
valueThe float value to write.

◆ WriteFloatArray()

void Apache::Geode::Client::DataOutput::WriteFloatArray ( array< float >^  value)

Write a float array to the DataOutput.

Parameters
valueThe float array to write.

◆ WriteInt16()

void Apache::Geode::Client::DataOutput::WriteInt16 ( System::Int16  value)

Write a 16-bit integer to the DataOutput.

Parameters
valueThe 16-bit integer to write.

◆ WriteInt32()

void Apache::Geode::Client::DataOutput::WriteInt32 ( System::Int32  value)

Write a 32-bit integer to the DataOutput.

Parameters
valueThe 32-bit integer to write.

◆ WriteInt64()

void Apache::Geode::Client::DataOutput::WriteInt64 ( System::Int64  value)

Write a 64-bit integer to the DataOutput.

Parameters
valueThe 64-bit integer to write.

◆ WriteIntArray()

void Apache::Geode::Client::DataOutput::WriteIntArray ( array< Int32 >^  value)

Write a int array to the DataOutput.

Parameters
valueThe int array to write.

◆ WriteLongArray()

void Apache::Geode::Client::DataOutput::WriteLongArray ( array< Int64 >^  value)

Write a long array to the DataOutput.

Parameters
valueThe long array to write.

◆ WriteObject()

void Apache::Geode::Client::DataOutput::WriteObject ( Object^  obj)

Write a Serializable object to the DataOutput.

This is provided to conveniently pass primitive types (like string) that shall be implicitly converted to corresponding ISerializable wrapper types.

Parameters
objThe object to write.

◆ WriteObjectArray()

void Apache::Geode::Client::DataOutput::WriteObjectArray ( List< Object^>^  value)

Write a object array to the DataOutput.

Parameters
valueThe object array to write.

◆ WriteSByte()

void Apache::Geode::Client::DataOutput::WriteSByte ( SByte  value)

Write a signed byte to the DataOutput.

Parameters
valueThe signed byte to write.

◆ WriteSBytes() [1/2]

void Apache::Geode::Client::DataOutput::WriteSBytes ( array< SByte >^  bytes)
inline

Write an array of signed bytes to the DataOutput.

Parameters
bytesThe array of signed bytes to write.

◆ WriteSBytes() [2/2]

void Apache::Geode::Client::DataOutput::WriteSBytes ( array< SByte >^  bytes,
System::Int32  len 
)

Write a given length of signed bytes to the DataOutput.

Parameters
bytesThe array of signed bytes to write.
lenThe number of bytes from the start of array to write.

◆ WriteSBytesOnly() [1/2]

void Apache::Geode::Client::DataOutput::WriteSBytesOnly ( array< SByte >^  bytes)
inline

Write an array of signed bytes without its length to the DataOutput.

Parameters
bytesThe array of signed bytes to write.

◆ WriteSBytesOnly() [2/2]

void Apache::Geode::Client::DataOutput::WriteSBytesOnly ( array< SByte >^  bytes,
System::UInt32  len 
)

Write a given length of signed bytes without its length to the DataOutput.

Parameters
bytesThe array of signed bytes to write.
lenThe number of bytes from the start of array to write.

◆ WriteShortArray()

void Apache::Geode::Client::DataOutput::WriteShortArray ( array< Int16 >^  value)

Write a short array to the DataOutput.

Parameters
valueThe short array to write.

◆ WriteUTF()

void Apache::Geode::Client::DataOutput::WriteUTF ( String^  value)

Write a string using java-modified UTF-8 encoding to DataOutput.

The maximum length supported is 2^16-1 beyond which the string shall be truncated.

Parameters
valueThe UTF encoded string to write.

Property Documentation

◆ BufferLength

size_t Apache::Geode::Client::DataOutput::BufferLength
get

Get the length of current data in the buffer.


Apache Geode C++ Cache .NET API Documentation