Verifies that an object can be serialized to a stream using a BinaryFormatter
and returns the resulting stream.
Namespace:
MbUnit.FrameworkAssembly: MbUnit (in MbUnit.dll) Version: 3.3.0.0 (3.3.610.0)
Syntax
| C# |
|---|
public static MemoryStream BinarySerialize( Object value ) |
| Visual Basic (Declaration) |
|---|
Public Shared Function BinarySerialize ( _ value As Object _ ) As MemoryStream |
Parameters
- value
- Type: System..::.Object
The value.
Return Value
The serialized stream.
Remarks
The assertion fails if value is null.
Exceptions
| Exception | Condition |
|---|---|
| Gallio.Framework.Assertions..::.AssertionException | Thrown if the verification failed unless the current AssertionFailureBehavior indicates otherwise. |
