The base class for predicates that applies to a ReferenceValidationContext. Standard extension methods are provided on ReferencePredicateExtensions. You can create your own predicates by deriving a new class from this one and exposing the API as a extension methods of ReferencePredicateBuilder.
Implements
Namespace: Metalama.Extensions.Architecture.Predicates
Assembly: Metalama.Extensions.Architecture.dll
Syntax
public abstract class ReferencePredicate : ICompileTimeSerializableRemarks
This class implements ICompileTimeSerializable. All predicates must therefore be serializable.
Constructors
| Name | Description |
|---|---|
| ReferencePredicate(ReferencePredicateBuilder) | Initializes a new instance of the ReferencePredicate class and provides a ReferencePredicateBuilder. |
Properties
| Name | Description |
|---|---|
| Builder | Gets the ReferencePredicateBuilder from which the current predicate was built,
or |
| Granularity | Gets the granularity including the modifiers such as |
Methods
| Name | Description |
|---|---|
| GetGranularity() | Gets the granularity of validation required by this predicate, effect ignoring any modifier such as |
| IsMatch(ReferenceValidationContext) | Gets a value indicating whether the predicate matches the given ReferenceValidationContext,
taking the optional modifier (e.g. an |
| IsMatchCore(ReferenceValidationContext) | Gets a value indicating whether the current predicate matches the given ReferenceValidationContext,
ignoring any modifier such as |