ChildParameter Struct

Represents a parameter that is associated with a child element in the XML binding schema.

C#
public record struct ChildParameter : IEquatable<ChildParameter>
Inheritance
ChildParameter
Implements

Constructors

ChildParameter(Type, SchemaType, XmlQualifiedName, ParameterInfo)

Represents a parameter that is associated with a child element in the XML binding schema.

Properties

UnitType

The type of the unit represented by this parameter. This type must be a class attributed with ForElementAttribute.

SchemaType

The schema type that describes how the parameter is mapped and processed in the schema.

ElementName

The qualified name of the XML element associated with the UnitType.

Info

The ParameterInfo instance that provides metadata about the parameter.

SchemaTypeMap

Gets a mapping from attribute types to their corresponding schema types.

AttributeTypes

Gets the collection of attribute types that are supported for schema mapping.

Methods

ToSchemaType(Type)

Gets the SchemaType associated with the specified attribute type.

Of(ParameterInfo, QNameBank)

Creates a ChildParameter instance from the specified ParameterInfo.

Equals(object) (Inherited from ValueType)
GetHashCode() (Inherited from ValueType)
ToString() (Inherited from ValueType)
GetType() (Inherited from object)
MemberwiseClone() (Inherited from object)

Constructors Detail

ChildParameter(Type, SchemaType, XmlQualifiedName, ParameterInfo)

Represents a parameter that is associated with a child element in the XML binding schema.

C#
public ChildParameter(Type UnitType, SchemaType SchemaType, XmlQualifiedName ElementName, ParameterInfo Info)

Parameters

UnitType
Type

The type of the unit represented by this parameter. This type must be a class attributed with ForElementAttribute.

SchemaType
SchemaType

The schema type that describes how the parameter is mapped and processed in the schema.

ElementName
XmlQualifiedName

The qualified name of the XML element associated with the UnitType.

Info
ParameterInfo

The ParameterInfo instance that provides metadata about the parameter.

Properties Detail

UnitType

The type of the unit represented by this parameter. This type must be a class attributed with ForElementAttribute.

C#
public Type UnitType { get; set; }

Property Value

SchemaType

The schema type that describes how the parameter is mapped and processed in the schema.

C#
public SchemaType SchemaType { get; set; }

Property Value

ElementName

The qualified name of the XML element associated with the UnitType.

C#
public XmlQualifiedName ElementName { get; set; }

Property Value

Info

The ParameterInfo instance that provides metadata about the parameter.

C#
public ParameterInfo Info { get; set; }

Property Value

SchemaTypeMap

Gets a mapping from attribute types to their corresponding schema types.

C#
public static IReadOnlyDictionary<Type, SchemaType> SchemaTypeMap { get; }

Property Value

AttributeTypes

Gets the collection of attribute types that are supported for schema mapping.

C#
public static IReadOnlyCollection<Type> AttributeTypes { get; }

Property Value

Methods Detail

ToSchemaType(Type)

Gets the SchemaType associated with the specified attribute type.

C#
public static SchemaType ToSchemaType(Type type)

Parameters

type
Type

The attribute type.

Returns

The corresponding SchemaType, or null if the type is not mapped.

Of(ParameterInfo, QNameBank)

Creates a ChildParameter instance from the specified ParameterInfo.

C#
public static ChildParameter Of(ParameterInfo p, QNameBank nameBank)

Parameters

p
ParameterInfo

The parameter information.

nameBank
QNameBank

The QNameBank instance used to intern XML qualified names.

Returns

A ChildParameter representing the parameter.