Doublet Struct
Encapsulates the element type and the value transformation logic (sugarcoater) for a constructor parameter representing a child XML element.
C#
public readonly struct Doublet
- Inheritance
Remarks
This is used to determine the actual type of the object to be created for a child element and how to wrap it (e.g., with BindResult<T>) if necessary.
Properties
Element |
Gets the element type (e.g., |
Sugarcoater |
Gets the sugarcoater. |
Methods
Of(Type) |
Creates a new Doublet for the specified constructor parameter type. |
Equals(object) |
(Inherited from Value |
GetHashCode() |
(Inherited from Value |
ToString() |
(Inherited from Value |
GetType() | (Inherited from object) |
MemberwiseClone() | (Inherited from object) |
Properties Detail
ElementType
Gets the element type (e.g., T
or BindResult<T>).
C#
public Type ElementType { get; }
Property Value
Sugarcoater
Gets the sugarcoater.
C#
public Sugarcoater<object> Sugarcoater { get; }
Property Value
Methods Detail
Of(Type)
Creates a new Doublet for the specified constructor parameter type.
C#
public static Doublet Of(Type type)
Parameters
- type
- Type
The type.
Returns
The new doublet.