Interface ICustomObjectCreator
Used to control type creation during deserialization. For example, it can be used to create object proxies.
Namespace: Couchbase.Core.IO.Serializers
Assembly: Couchbase.NetClient.dll
Syntax
public interface ICustomObjectCreator
Methods
| Edit this page View SourceCanCreateObject(Type)
Determine if this creator can create a particular type.
Declaration
bool CanCreateObject(Type type)
Parameters
Type | Name | Description |
---|---|---|
Type | type | Type to test. |
Returns
Type | Description |
---|---|
bool | True if this creator can create a particular type. |
Remarks
Results of this method should be consistent for every call so that they can be cached.
CreateObject(Type)
Create an instance of a particular type with default values, ready to be populated by the deserializer.
Declaration
object CreateObject(Type type)
Parameters
Type | Name | Description |
---|---|---|
Type | type | Type to create. |
Returns
Type | Description |
---|---|
object | New instance of the type with default values, ready to be populated by the deserializer. |