RangeSyntax<T> Class
Represents a range expression that can evaluate whether a value falls within the range.
public abstract class RangeSyntax<T>Type parameters
T- The type of values in the range.
Methods
| Name | Description |
|---|---|
| IsInRange(T) | Determines whether a value is within the range using the default comparer. |
| IsInRange(T, IComparer<T>?) | Determines whether a value is within the range using a custom comparer. |
IsInRange overloads
IsInRange(T)
RangeSyntax`1.csIsInRange(T, IComparer<T>?)
Determines whether a value is within the range using a custom comparer.
Parameters
valueT- The value to check.
comparerIComparer<T>?- The comparer to use for comparison, or null to use the default comparer.
Returns
bool true if the value is within the range; otherwise, false.