| TransformerTToBytes Method (T, Encoding, Byte, Int32) | 
 Transforms instance into a byte array.
 
    Namespace: 
   Enkoni.Framework.Serialization
    Assembly:
   Enkoni.Framework.Serialization (in Enkoni.Framework.Serialization.dll) Version: 1.3.0.1
 Syntax
Syntaxpublic int ToBytes(
	T instance,
	Encoding encoding,
	byte[] bytes,
	int offset
)
Public Function ToBytes ( 
	instance As T,
	encoding As Encoding,
	bytes As Byte(),
	offset As Integer
) As Integer
public:
int ToBytes(
	T instance, 
	Encoding^ encoding, 
	array<unsigned char>^ bytes, 
	int offset
)
member ToBytes : 
        instance : 'T * 
        encoding : Encoding * 
        bytes : byte[] * 
        offset : int -> int 
Parameters
- instance
- Type: T
 The instance that must be transformed.
- encoding
- Type: System.TextEncoding
 The encoding that must be used to transform the instance into bytes.
- bytes
- Type: SystemByte
 The byte array into which the transformed instance must be stored.
- offset
- Type: SystemInt32
 The offset in bytes.
Return Value
Type: 
Int32The number of bytes that were written into 
bytes.
 Exceptions
Exceptions See Also
See Also