Method | Description | |
---|---|---|
EndianBinaryWriter ( Stream output ) : System | ||
Write ( String text ) : void |
Method Write, writes a string to the output using the WriteString16 method.
|
|
Write ( char chars ) : void |
Method Write
|
|
Write ( char chars, int index, int count ) : void |
Method Write
|
|
Write ( double value ) : void |
Method Write
|
|
Write ( float value ) : void |
Method Write
|
|
Write ( int value ) : void |
Method Write
|
|
Write ( long value ) : void |
Method Write
|
|
Write ( short value ) : void |
Method Write
|
|
Write ( uint value ) : void |
Method Write
|
|
Write ( ulong value ) : void |
Method Write
|
|
Write ( ushort value ) : void |
Method Write
|
|
WriteString16 ( String text ) : void |
Method WriteString16, writes a string to the output using the Java standard modified UTF-8 encoding with an unsigned short value written first to indicate the length of the encoded data, the short is read as an unsigned value so the max amount of data this method can write is 65535 encoded bytes. Unlike the WriteString32 method this method does not encode the length value to -1 if the string is null, this is to match the behaviour of the Java DataOuputStream class's writeUTF method. Because modified UTF-8 encding can result in a number of bytes greater that the size of the String this method must first check that the encoding proces will not result in a value that cannot be written becuase it is greater than the max value of an unsigned short.
|
|
WriteString32 ( String text ) : void |
Method WriteString32, writes a string to the output using the Openwire standard modified UTF-8 encoding which an int value written first to indicate the length of the encoded data, the int is read as an signed value so the max amount of data this method can write is 2^31 encoded bytes. In the case of a null value being passed this method writes a -1 to the stream to indicate that the string is null. Because modified UTF-8 encding can result in a number of bytes greater that the size of the String this method must first check that the encoding proces will not result in a value that cannot be written becuase it is greater than the max value of an int.
|
Method | Description | |
---|---|---|
CountUtf8Bytes ( char chars ) : uint | ||
encodeUTF8toBuffer ( char chars, byte buffer ) : void |
public EndianBinaryWriter ( Stream output ) : System | ||
output | Stream | |
return | System |
public Write ( char chars, int index, int count ) : void | ||
chars | char | A char[] |
index | int | An int |
count | int | An int |
return | void |
public WriteString16 ( String text ) : void | ||
text | String | A string |
return | void |
public WriteString32 ( String text ) : void | ||
text | String | A string |
return | void |