Save an object to bytes.
Assembly: Cognex.Vision.Core.Net (in Cognex.Vision.Core.Net.dll) Version: 9.22.2.0
Syntax
Parameters
- obj (Optional)
- Type: IObject
The object to save.
- option (Optional)
- Type: Cognex.Vision SerializerOptionsConstants
The option bits specifying what should be persisted. Default Value: Cognex.Vision.SerializerOptionsConstants.All.
Return Value
Type: UInt8CollectionThe bytes.
Exceptions
| Exception | Condition |
|---|---|
| ArgumentException | The supplied object reference is null. |
| ArgumentException | The option argument is not valid. |
See Also