Class StreamExtensions
Provides extension methods for
Inheritance
Inherited Members
Namespace: Gremlin.Net.Structure.IO.GraphBinary
Assembly: cs.temp.dll.dll
Syntax
public static class StreamExtensions
Methods
ReadAsync(Stream, Int32)
Asynchronously reads a byte[] from a
Declaration
public static async Task<byte[]> ReadAsync(this Stream stream, int count)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
System.Int32 | count | The number of bytes to read. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Byte[]> | The read byte[]. |
ReadBoolAsync(Stream)
Asynchronously reads a System.Boolean from a
Declaration
public static async Task<bool> ReadBoolAsync(this Stream stream)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Boolean> | The read System.Boolean. |
ReadByteAsync(Stream)
Asynchronously reads a System.Byte from a
Declaration
public static async Task<byte> ReadByteAsync(this Stream stream)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Byte> | The read System.Byte. |
ReadDoubleAsync(Stream)
Asynchronously reads a System.Double from a
Declaration
public static async Task<double> ReadDoubleAsync(this Stream stream)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Double> | The read System.Double. |
ReadFloatAsync(Stream)
Asynchronously reads a System.Single from a
Declaration
public static async Task<float> ReadFloatAsync(this Stream stream)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Single> | The read System.Single. |
ReadIntAsync(Stream)
Asynchronously reads an System.Int32 from a
Declaration
public static async Task<int> ReadIntAsync(this Stream stream)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Int32> | The read System.Int32. |
ReadLongAsync(Stream)
Asynchronously reads a System.Int64 from a
Declaration
public static async Task<long> ReadLongAsync(this Stream stream)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Int64> | The read System.Int64. |
ReadShortAsync(Stream)
Asynchronously reads a System.Int16 from a
Declaration
public static async Task<short> ReadShortAsync(this Stream stream)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Int16> | The read System.Int16. |
WriteAsync(Stream, Byte[])
Asynchronously writes a byte[] to a
Declaration
public static async Task WriteAsync(this Stream stream, byte[] value)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
System.Byte[] | value | The byte[] to write. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |
WriteBoolAsync(Stream, Boolean)
Asynchronously writes a System.Boolean to a
Declaration
public static async Task WriteBoolAsync(this Stream stream, bool value)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
System.Boolean | value | The System.Boolean to write. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |
WriteByteAsync(Stream, Byte)
Asynchronously writes a System.Byte to a
Declaration
public static async Task WriteByteAsync(this Stream stream, byte value)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
System.Byte | value | The System.Byte to write. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |
WriteDoubleAsync(Stream, Double)
Asynchronously writes a System.Double to a
Declaration
public static async Task WriteDoubleAsync(this Stream stream, double value)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
System.Double | value | The System.Double to write. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |
WriteFloatAsync(Stream, Single)
Asynchronously writes a System.Single to a
Declaration
public static async Task WriteFloatAsync(this Stream stream, float value)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
System.Single | value | The System.Single to write. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |
WriteIntAsync(Stream, Int32)
Asynchronously writes an System.Int32 to a
Declaration
public static async Task WriteIntAsync(this Stream stream, int value)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
System.Int32 | value | The System.Int32 to write. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |
WriteLongAsync(Stream, Int64)
Asynchronously writes a System.Int64 to a
Declaration
public static async Task WriteLongAsync(this Stream stream, long value)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
System.Int64 | value | The System.Int64 to write. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |
WriteShortAsync(Stream, Int16)
Asynchronously writes a System.Int16 to a
Declaration
public static async Task WriteShortAsync(this Stream stream, short value)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The |
System.Int16 | value | The System.Int16 to write. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |