WebRTC Network  0.96
Properties | List of all members
Byn.Net.MessageDataBuffer Interface Reference

More...

Inheritance diagram for Byn.Net.MessageDataBuffer:
Byn.Net.ByteArrayBuffer

Properties

byte[] Buffer [get]
 Returns the buffer that contains the message data. Don't use Buffer.Length! The buffer might be longer than the actually message. use ContentLength to get the length of the content More...
 
int Offset [get]
 
int ContentLength [get]
 Returns the length of the buffers content. The byte array might be longer than the actual content! Always use this property not Buffer.Length !!! More...
 

Detailed Description

This interface is used to return binary message data.

Use MessageDataBuffer.Buffer only to read data between the index Offset and Offset + MessageDataBuffer.ContentLength.

After reading use Dispose to allow the network to reuse this buffer and spare the Garbage Collector the work.

Make sure not to keep any references to MessageDataBuffer.Buffer after calling Dispose! If you need to store the byte array create a copy of the content before using Dispose.

Property Documentation

byte [] Byn.Net.MessageDataBuffer.Buffer
get

Returns the buffer that contains the message data. Don't use Buffer.Length! The buffer might be longer than the actually message. use ContentLength to get the length of the content

int Byn.Net.MessageDataBuffer.ContentLength
get

Returns the length of the buffers content. The byte array might be longer than the actual content! Always use this property not Buffer.Length !!!


The documentation for this interface was generated from the following file: