Class RegexCondition
- Namespace
- The.SQL.QIR.Conditions
- Assembly
- Instagile.dll
Tests whether the Subject value matches the regular expression given by
Pattern. Produced by Regex.IsMatch(value, pattern).
[MessagePackObject(false)]
public sealed record RegexCondition : Condition, IEquatable<Condition>, IEquatable<RegexCondition>
- Inheritance
-
RegexCondition
- Implements
- Inherited Members
Remarks
The regex grammar is whatever the backend natively understands:
- TransientEntityStore and SQLiteEntityStore use the .NET engine directly
- PostgreSQL uses POSIX ARE
- SQL Server uses its
REGEXP_LIKEengine Only the IgnoreCase option is translated programmatically; use inline flags (such as(?i)or(?m)) for anything else, as those are understood by every backend.
Constructors
RegexCondition(Value, Value, bool)
Tests whether the Subject value matches the regular expression given by
Pattern. Produced by Regex.IsMatch(value, pattern).
public RegexCondition(Value Subject, Value Pattern, bool IgnoreCase = false)
Parameters
Remarks
The regex grammar is whatever the backend natively understands:
- TransientEntityStore and SQLiteEntityStore use the .NET engine directly
- PostgreSQL uses POSIX ARE
- SQL Server uses its
REGEXP_LIKEengine Only the IgnoreCase option is translated programmatically; use inline flags (such as(?i)or(?m)) for anything else, as those are understood by every backend.
Properties
IgnoreCase
[Key(2)]
public bool IgnoreCase { get; init; }
Property Value
Joins
Joins required to reach this condition.
[IgnoreMember]
public override IEnumerable<Join> Joins { get; }
Property Value
Pattern
[Key(1)]
public Value Pattern { get; init; }
Property Value
Subject
[Key(0)]
public Value Subject { get; init; }
Property Value
Methods
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.
Update(Value, Value, bool)
public RegexCondition Update(Value left, Value pattern, bool ignoreCase)
Parameters
Returns
WithSource(Table, Table)
public override Condition WithSource(Table oldSource, Table newSource)