(One intermediate revision by the same user not shown)
Line 3:
Line 3:
|Name=Nullable Source Driver`1
|Name=Nullable Source Driver`1
}}
}}
{{stub}}
The '''NullableSourceDriver''' component allows for getting info from a <code>Source</code> nullable and driving a set of split fields with content from the nullable. Changes to driven fields by this component can also be reverse written back to <code>Source</code>.
|Source|{{RootFieldType|RelayRef`1|[[Type:IField`1|IField`1]]<[[Type:Nullable`1|Nullable`1]]<T>>}}|TypeAdv0=true| The field to get nullable data from.
|Value|{{RootFieldType|FieldDrive`1|T}}|TypeAdv1=true| The field to drive with the value for <code>Source</code> if it has a value, or instead drive with <code>DefaultValue</code>.
|HasValue|{{RootFieldType|FieldDrive`1|[[Type:Bool|Bool]]}}|TypeAdv2=true| The field to drive with whether <code>Source</code> has a value.
|DefaultValue|'''T'''|TypeAdv3=true|
|DefaultValue|'''T'''|TypeAdv3=true| The default value if <code>Source</code> doesn't have a value.
|WriteBack|Bool|
|WriteBack|Bool| Whether writes to the fields driven by this component will update the value of <code>Source</code>. See [[Drives#Write Backs|write backs]].
|UpdateDefaultValue|Bool|
|UpdateDefaultValue|Bool| Whether the default value gets updated when using write back and <code>Source</code> has no value.
}}
}}
== Behavior ==
== Usage ==
Can be used to extract data from nullables or write to them using a component only solution.
Nullable Source Driver`1 component as seen in the Scene Inspector
The NullableSourceDriver component allows for getting info from a Source nullable and driving a set of split fields with content from the nullable. Changes to driven fields by this component can also be reverse written back to Source.