GemStone::GemFire::Cache::Generic::DataOutput Class Reference

Inherits GemStone::GemFire::Cache::Generic::Internal::UMWrap< gemfire::DataOutput >.


Detailed Description

Provides operations for writing primitive data values, and user-defined objects implementing IGFSerializable, to a byte stream. This class is intentionally not thread safe.

Public Member Functions

void AdvanceCursor (uint32_t offset)
 DataOutput ()
array< Byte >^ GetBuffer ()
void Reset ()
void RewindCursor (uint32_t offset)
void WriteArrayLen (int32_t len)
void WriteArrayOfByteArrays (array< array< Byte >^>^value)
void WriteASCIIHuge (String^ value)
void WriteBoolean (bool value)
void WriteBooleanArray (array< bool >^value)
void WriteBytes (array< Byte >^bytes)
void WriteBytes (array< Byte >^bytes, int32_t len)
void WriteBytesOnly (array< Byte >^bytes)
void WriteBytesOnly (array< Byte >^bytes, uint32_t len)
void WriteChar (Char value)
void WriteCharArray (array< Char >^value)
void WriteCollection (System::Collections::IList^ value)
void WriteDate (System::DateTime value)
void WriteDictionary (System::Collections::IDictionary^ value)
void WriteDouble (double value)
void WriteDoubleArray (array< double >^value)
void WriteFloat (float value)
void WriteFloatArray (array< float >^value)
void WriteInt16 (int16_t value)
void WriteInt32 (int32_t value)
void WriteInt64 (int64_t value)
void WriteIntArray (array< Int32 >^value)
void WriteLongArray (array< Int64 >^value)
void WriteObject (Object^ obj)
void WriteObjectArray (List< Object^ >^value)
void WriteSByte (SByte value)
void WriteSBytes (array< SByte >^bytes)
void WriteSBytes (array< SByte >^bytes, int32_t len)
void WriteSBytesOnly (array< SByte >^bytes)
void WriteSBytesOnly (array< SByte >^bytes, uint32_t len)
void WriteShortArray (array< Int16 >^value)
void WriteUTF (String^ value)
void WriteUTFHuge (String^ value)

Protected Member Functions

void InternalCleanup ()
void SetPtr (gemfire::DataOutput *nativeptr, bool own)

Properties

uint32_t BufferLength [get]
IntPtr NativeIntPtr [get]
bool Own [get, set]

Constructor & Destructor Documentation

GemStone::GemFire::Cache::Generic::DataOutput::DataOutput (  )  [inline]

Default constructor.


Member Function Documentation

void GemStone::GemFire::Cache::Generic::DataOutput::AdvanceCursor ( uint32_t  offset  ) 

Advance the buffer cursor by the given offset.

Parameters:
offset The offset by which to advance the cursor.

array<Byte> ^ GemStone::GemFire::Cache::Generic::DataOutput::GetBuffer (  ) 

Get a copy of the current buffer.

void GemStone::GemFire::Cache::Generic::Internal::UMWrap< gemfire::DataOutput >::InternalCleanup (  )  [inline, protected, inherited]

Internal cleanup function invoked by dispose/finalizer.

void GemStone::GemFire::Cache::Generic::DataOutput::Reset (  ) 

Reset the cursor to the start of the buffer.

void GemStone::GemFire::Cache::Generic::DataOutput::RewindCursor ( uint32_t  offset  ) 

Rewind the buffer cursor by the given offset.

Parameters:
offset The offset by which to rewind the cursor.

void GemStone::GemFire::Cache::Generic::Internal::UMWrap< gemfire::DataOutput >::SetPtr ( gemfire::DataOutput *  nativeptr,
bool  own 
) [inline, protected, inherited]

Used to set the native pointer to a new object. This should only be used when you know that the underlying object is NULL or you do not own it.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteArrayLen ( int32_t  len  ) 

Write length of the array to the DataOutput.

Parameters:
len Array len to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteArrayOfByteArrays ( array< array< Byte >^>^  value  ) 

Write a array of sign byte array to the DataOutput.

Parameters:
value The array of sign byte array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteASCIIHuge ( String^   value  ) 

Write a string(only ASCII char) to DataOutput. Length should be more than 2^16 -1.

Parameters:
value The UTF encoded string to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteBoolean ( bool  value  ) 

Write a boolean value to the DataOutput.

Parameters:
value The boolean value to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteBooleanArray ( array< bool >^  value  ) 

Write a bool array to the DataOutput.

Parameters:
value The bool array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteBytes ( array< Byte >^  bytes  )  [inline]

Write an array of bytes to the DataOutput.

Parameters:
bytes The array of bytes to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteBytes ( array< Byte >^  bytes,
int32_t  len 
)

Write a given length of bytes to the DataOutput.

Parameters:
bytes The array of bytes to write.
len The number of bytes from the start of array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteBytesOnly ( array< Byte >^  bytes  )  [inline]

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

Parameters:
bytes The array of bytes to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteBytesOnly ( array< Byte >^  bytes,
uint32_t  len 
)

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

Parameters:
bytes The array of bytes to write.
len The number of bytes from the start of array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteChar ( Char  value  ) 

Write a char value to the DataOutput.

Parameters:
value The char value to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteCharArray ( array< Char >^  value  ) 

Write a char array to the DataOutput.

Parameters:
value The char array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteCollection ( System::Collections::IList^   value  ) 

Write a collection to the DataOutput.

Parameters:
value The object which implements IList to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteDate ( System::DateTime  value  ) 

Write a date to the DataOutput.

Parameters:
value The date value to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteDictionary ( System::Collections::IDictionary^   value  ) 

Write a Dictionary to the DataOutput.

Parameters:
value The object which implements IDictionary to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteDouble ( double  value  ) 

Write a double precision real number to the DataOutput.

Parameters:
value The double precision real number to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteDoubleArray ( array< double >^  value  ) 

Write a double array to the DataOutput.

Parameters:
value The double array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteFloat ( float  value  ) 

Write a float to the DataOutput.

Parameters:
value The float value to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteFloatArray ( array< float >^  value  ) 

Write a float array to the DataOutput.

Parameters:
value The float array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteInt16 ( int16_t  value  ) 

Write a 16-bit integer to the DataOutput.

Parameters:
value The 16-bit integer to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteInt32 ( int32_t  value  ) 

Write a 32-bit integer to the DataOutput.

Parameters:
value The 32-bit integer to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteInt64 ( int64_t  value  ) 

Write a 64-bit integer to the DataOutput.

Parameters:
value The 64-bit integer to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteIntArray ( array< Int32 >^  value  ) 

Write a int array to the DataOutput.

Parameters:
value The int array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteLongArray ( array< Int64 >^  value  ) 

Write a long array to the DataOutput.

Parameters:
value The long array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteObject ( Object^   obj  ) 

Write an IGFSerializable object to the DataOutput.

Parameters:
obj The object to write.
Write a Serializable object to the DataOutput. This is provided to conveniently pass primitive types (like string) that shall be implicitly converted to corresponding IGFSerializable wrapper types.

Parameters:
obj The object to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteObjectArray ( List< Object^ >^  value  ) 

Write a object array to the DataOutput.

Parameters:
value The object array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteSByte ( SByte  value  ) 

Write a signed byte to the DataOutput.

Parameters:
value The signed byte to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteSBytes ( array< SByte >^  bytes  )  [inline]

Write an array of signed bytes to the DataOutput.

Parameters:
bytes The array of signed bytes to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteSBytes ( array< SByte >^  bytes,
int32_t  len 
)

Write a given length of signed bytes to the DataOutput.

Parameters:
bytes The array of signed bytes to write.
len The number of bytes from the start of array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteSBytesOnly ( array< SByte >^  bytes  )  [inline]

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

Parameters:
bytes The array of signed bytes to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteSBytesOnly ( array< SByte >^  bytes,
uint32_t  len 
)

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

Parameters:
bytes The array of signed bytes to write.
len The number of bytes from the start of array to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteShortArray ( array< Int16 >^  value  ) 

Write a short array to the DataOutput.

Parameters:
value The short array to write.

void GemStone::GemFire::Cache::Generic::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:
value The UTF encoded string to write.

void GemStone::GemFire::Cache::Generic::DataOutput::WriteUTFHuge ( String^   value  ) 

Write a string using java-modified UTF-8 encoding to DataOutput. Length should be more than 2^16 -1.

Parameters:
value The UTF encoded string to write.


Property Documentation

uint32_t GemStone::GemFire::Cache::Generic::DataOutput::BufferLength [get]

Get the length of current data in the buffer.

IntPtr GemStone::GemFire::Cache::Generic::DataOutput::NativeIntPtr [get]

Get the underlying native unmanaged pointer.

bool GemStone::GemFire::Cache::Generic::Internal::UMWrap< gemfire::DataOutput >::Own [get, set, protected, inherited]

Get or set the ownership of this object.

Returns:
True if the native object is owned by this object.


GemFire C++ Cache .NET API Documentation