Skip to main content

Class NetworkReaderPool

Holds static reference to of

Inheritance
System.Object
Inherited Members
Show
Syntax
public static class NetworkReaderPool

Methods

Configure(Int32, Int32)

Declaration
public static void Configure(int startPoolSize = 5, int maxPoolSize = 100)
Parameters
TypeNameDescription
System.Int32startPoolSize
System.Int32maxPoolSize

GetReader(ArraySegment<Byte>, IObjectLocator)

Gets reader from pool. sets internal array and objectLocator values

Declaration
public static PooledNetworkReader GetReader(ArraySegment<byte> packet, IObjectLocator objectLocator)
Parameters
TypeNameDescription
System.ArraySegment<System.Byte>packet
Mirage.IObjectLocatorobjectLocatorCan be null, but must be set in order to read NetworkIdentity Values
Returns
TypeDescription
Mirage.Serialization.PooledNetworkReader

GetReader(Byte[], IObjectLocator)

Gets reader from pool. sets internal array and objectLocator values

Declaration
public static PooledNetworkReader GetReader(byte[] array, IObjectLocator objectLocator)
Parameters
TypeNameDescription
System.Byte[]array
Mirage.IObjectLocatorobjectLocatorCan be null, but must be set in order to read NetworkIdentity Values
Returns
TypeDescription
Mirage.Serialization.PooledNetworkReader

GetReader(Byte[], Int32, Int32, IObjectLocator)

Gets reader from pool. sets internal array and objectLocator values

Declaration
public static PooledNetworkReader GetReader(byte[] array, int offset, int length, IObjectLocator objectLocator)
Parameters
TypeNameDescription
System.Byte[]array
System.Int32offset
System.Int32length
Mirage.IObjectLocatorobjectLocatorCan be null, but must be set in order to read NetworkIdentity Values
Returns
TypeDescription
Mirage.Serialization.PooledNetworkReader