Class fsDirectConverter<TModel>
Inherited Members
Namespace: Unity.VisualScripting .FullSerializer
Assembly: Unity.VisualScripting.Core.dll
Syntax
public abstract class fsDirectConverter<TModel> : fsDirectConverter
Type Parameters
Name | Description |
---|---|
TModel |
Properties
ModelType
Declaration
public override Type ModelType { get; }
Property Value
Type | Description |
---|---|
Type |
Overrides
Methods
DoDeserialize(Dictionary<string, fsData>, ref TModel)
Declaration
protected abstract fsResult DoDeserialize(Dictionary<string, fsData> data, ref TModel model)
Parameters
Type | Name | Description |
---|---|---|
Dictionary<string, fs |
data | |
TModel | model |
Returns
Type | Description |
---|---|
fs |
DoSerialize(TModel, Dictionary<string, fsData>)
Declaration
protected abstract fsResult DoSerialize(TModel model, Dictionary<string, fsData> serialized)
Parameters
Type | Name | Description |
---|---|---|
TModel | model | |
Dictionary<string, fs |
serialized |
Returns
Type | Description |
---|---|
fs |
TryDeserialize(fsData, ref object, Type)
Deserialize data into the object instance.
Declaration
public override sealed fsResult TryDeserialize(fsData data, ref object instance, Type storageType)
Parameters
Type | Name | Description |
---|---|---|
fs |
data | Serialization data to deserialize from. |
object | instance | The object instance to deserialize into. |
Type | storageType | The field/property type that is storing the instance. |
Returns
Type | Description |
---|---|
fs |
True if serialization was successful, false otherwise. |
Overrides
TrySerialize(object, out fsData, Type)
Serialize the actual object into the given data storage.
Declaration
public override sealed fsResult TrySerialize(object instance, out fsData serialized, Type storageType)
Parameters
Type | Name | Description |
---|---|---|
object | instance | The object instance to serialize. This will never be null. |
fs |
serialized | The serialized state. |
Type | storageType | The field/property type that is storing this instance. |
Returns
Type | Description |
---|---|
fs |
If serialization was successful. |