Table of Contents

Class CorLibScopePattern

Namespace
CilFi.Patterns
Assembly
CilFi.Core.dll

Defines the pattern matching on CorLib assembly resolution scopes (e.g., mscorlib, netstandard or System.Runtime).

public record CorLibScopePattern : Pattern<IResolutionScope>, IEquatable<Pattern>, IEquatable<Pattern<IResolutionScope>>, IEquatable<CorLibScopePattern>
Inheritance
CorLibScopePattern
Implements
Inherited Members

Constructors

CorLibScopePattern()

public CorLibScopePattern()

CorLibScopePattern(CorLibScopePattern)

protected CorLibScopePattern(CorLibScopePattern original)

Parameters

original CorLibScopePattern

Properties

EqualityContract

protected override Type EqualityContract { get; }

Property Value

Type

Instance

Gets the singleton instance of the CorLibScopePattern.

public static CorLibScopePattern Instance { get; }

Property Value

CorLibScopePattern

Methods

Equals(CorLibScopePattern?)

public virtual bool Equals(CorLibScopePattern? other)

Parameters

other CorLibScopePattern

Returns

bool

Equals(Pattern<IResolutionScope>?)

public override sealed bool Equals(Pattern<IResolutionScope>? other)

Parameters

other Pattern<IResolutionScope>

Returns

bool

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object

Returns

bool

Format(IndentedTextWriter)

Serializes the pattern to a readable string.

public override void Format(IndentedTextWriter writer)

Parameters

writer IndentedTextWriter

The output stream.

GetHashCode()

public override int GetHashCode()

Returns

int

Match(IResolutionScope, MatchingContext)

Attempts to match the provided input to the pattern.

public override IMatchNode<IResolutionScope>? Match(IResolutionScope input, MatchingContext context)

Parameters

input IResolutionScope

The input to match.

context MatchingContext

The context in which to match the pattern to.

Returns

IMatchNode<IResolutionScope>

When successful, returns the root node of the match tree, otherwise null.

PrintMembers(StringBuilder)

protected override bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

Operators

operator ==(CorLibScopePattern?, CorLibScopePattern?)

public static bool operator ==(CorLibScopePattern? left, CorLibScopePattern? right)

Parameters

left CorLibScopePattern
right CorLibScopePattern

Returns

bool

operator !=(CorLibScopePattern?, CorLibScopePattern?)

public static bool operator !=(CorLibScopePattern? left, CorLibScopePattern? right)

Parameters

left CorLibScopePattern
right CorLibScopePattern

Returns

bool