Class FieldDescriptorPattern.MatchNode
Represents a match node produced by a FieldDescriptorPattern.
public sealed record FieldDescriptorPattern.MatchNode : IMatchNode<IFieldDescriptor>, IMatchNode, IEquatable<FieldDescriptorPattern.MatchNode>
- Inheritance
-
FieldDescriptorPattern.MatchNode
- Implements
- Inherited Members
Constructors
MatchNode(Pattern<IFieldDescriptor>, IFieldDescriptor, IMatchNode<TypeSignature>, IMatchNode<ITypeDefOrRef?>, IMatchNode<string?>)
Represents a match node produced by a FieldDescriptorPattern.
public MatchNode(Pattern<IFieldDescriptor> Pattern, IFieldDescriptor ConcreteValue, IMatchNode<TypeSignature> FieldType, IMatchNode<ITypeDefOrRef?> DeclaringType, IMatchNode<string?> Name)
Parameters
PatternPattern<IFieldDescriptor>ConcreteValueIFieldDescriptorFieldTypeIMatchNode<TypeSignature>DeclaringTypeIMatchNode<ITypeDefOrRef>NameIMatchNode<string>
Properties
ConcreteValue
Gets the value that matched the pattern.
public IFieldDescriptor ConcreteValue { get; init; }
Property Value
DeclaringType
public IMatchNode<ITypeDefOrRef?> DeclaringType { get; init; }
Property Value
FieldType
public IMatchNode<TypeSignature> FieldType { get; init; }
Property Value
Name
public IMatchNode<string?> Name { get; init; }
Property Value
Pattern
Gets the pattern that was matched.
public Pattern<IFieldDescriptor> Pattern { get; init; }
Property Value
Methods
Deconstruct(out Pattern<IFieldDescriptor>, out IFieldDescriptor, out IMatchNode<TypeSignature>, out IMatchNode<ITypeDefOrRef?>, out IMatchNode<string?>)
public void Deconstruct(out Pattern<IFieldDescriptor> Pattern, out IFieldDescriptor ConcreteValue, out IMatchNode<TypeSignature> FieldType, out IMatchNode<ITypeDefOrRef?> DeclaringType, out IMatchNode<string?> Name)
Parameters
PatternPattern<IFieldDescriptor>ConcreteValueIFieldDescriptorFieldTypeIMatchNode<TypeSignature>DeclaringTypeIMatchNode<ITypeDefOrRef>NameIMatchNode<string>
Equals(MatchNode?)
public bool Equals(FieldDescriptorPattern.MatchNode? other)
Parameters
Returns
Equals(object?)
public override bool Equals(object? obj)
Parameters
objobject
Returns
GetChildren()
Enumerates all child nodes of this match node.
public IEnumerable<(string Name, IMatchNode Match)> GetChildren()
Returns
GetHashCode()
public override int GetHashCode()
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(MatchNode?, MatchNode?)
public static bool operator ==(FieldDescriptorPattern.MatchNode? left, FieldDescriptorPattern.MatchNode? right)
Parameters
Returns
operator !=(MatchNode?, MatchNode?)
public static bool operator !=(FieldDescriptorPattern.MatchNode? left, FieldDescriptorPattern.MatchNode? right)