Class DataObjectQueryableExtensions
XData LINQ query extensions
Inherited Members
Namespace: XData.Extensions
Assembly: XData.docfx.dll
Syntax
public static class DataObjectQueryableExtensions
Methods
| Improve this Doc View SourceCompareToCurrentDate(DateTime, FilterOperation)
Compare value to current date
Declaration
public static bool CompareToCurrentDate(this DateTime source, FilterOperation operation)
Parameters
| Type | Name | Description |
|---|---|---|
| DateTime | source | Source property |
| FilterOperation | operation | Comparison operation |
Returns
| Type | Description |
|---|---|
| Boolean | Comparison result |
Exceptions
| Type | Condition |
|---|---|
| XDataQueryStructureException | LINQ expression has unsupported method parameters |
See Also
CompareToCurrentDate(Nullable<DateTime>, FilterOperation)
Compare value to current date
Declaration
public static bool CompareToCurrentDate(this DateTime? source, FilterOperation operation)
Parameters
| Type | Name | Description |
|---|---|---|
| Nullable<DateTime> | source | Source property |
| FilterOperation | operation | Comparison operation |
Returns
| Type | Description |
|---|---|
| Boolean | Comparison result |
Exceptions
| Type | Condition |
|---|---|
| XDataQueryStructureException | LINQ expression has unsupported method parameters |
See Also
CompareToCurrentDateTime(DateTime, FilterOperation)
Compare value to current date and time
Declaration
public static bool CompareToCurrentDateTime(this DateTime source, FilterOperation operation)
Parameters
| Type | Name | Description |
|---|---|---|
| DateTime | source | Source property |
| FilterOperation | operation | Comparison operation |
Returns
| Type | Description |
|---|---|
| Boolean | Comparison result |
Exceptions
| Type | Condition |
|---|---|
| XDataQueryStructureException | LINQ expression has unsupported method parameters |
See Also
CompareToCurrentDateTime(Nullable<DateTime>, FilterOperation)
Compare value to current date and time
Declaration
public static bool CompareToCurrentDateTime(this DateTime? source, FilterOperation operation)
Parameters
| Type | Name | Description |
|---|---|---|
| Nullable<DateTime> | source | Source property |
| FilterOperation | operation | Comparison operation |
Returns
| Type | Description |
|---|---|
| Boolean | Comparison result |
Exceptions
| Type | Condition |
|---|---|
| XDataQueryStructureException | LINQ expression has unsupported method parameters |
See Also
CompareToCurrentDateTimeUtc(DateTime, FilterOperation)
Compare value to current date and time UTC
Declaration
public static bool CompareToCurrentDateTimeUtc(this DateTime source, FilterOperation operation)
Parameters
| Type | Name | Description |
|---|---|---|
| DateTime | source | Source property |
| FilterOperation | operation | Comparison operation |
Returns
| Type | Description |
|---|---|
| Boolean | Comparison result |
Exceptions
| Type | Condition |
|---|---|
| XDataQueryStructureException | LINQ expression has unsupported method parameters |
See Also
| Improve this Doc View SourceCompareToCurrentDateTimeUtc(Nullable<DateTime>, FilterOperation)
Compare value to current date and time UTC
Declaration
public static bool CompareToCurrentDateTimeUtc(this DateTime? source, FilterOperation operation)
Parameters
| Type | Name | Description |
|---|---|---|
| Nullable<DateTime> | source | Source property |
| FilterOperation | operation | Comparison operation |
Returns
| Type | Description |
|---|---|
| Boolean | Comparison result |
Exceptions
| Type | Condition |
|---|---|
| XDataQueryStructureException | LINQ expression has unsupported method parameters |
See Also
CompareVariable(Object, FilterOperation, String)
Compare value to variable value WARNING! Method accessible only in XData LINQ expressions!
Declaration
public static bool CompareVariable(this object source, FilterOperation operation, string variableName)
Parameters
| Type | Name | Description |
|---|---|---|
| Object | source | Source property |
| FilterOperation | operation | Comparison operation |
| String | variableName | Variable name |
Returns
| Type | Description |
|---|---|
| Boolean | Comparison result |
Exceptions
| Type | Condition |
|---|---|
| XDataRuntimeException | Function is accessible in XData LINQ expressions only |
Like(String, String)
Like
Declaration
public static bool Like(this string source, string pattern)
Parameters
| Type | Name | Description |
|---|---|---|
| String | source | Source property |
| String | pattern | Like pattern |
Returns
| Type | Description |
|---|---|
| Boolean | Like result |
Exceptions
| Type | Condition |
|---|---|
| XDataRuntimeException | Like pattern can not be null or empty |
See Also
| Improve this Doc View SourceLike(String, String, Char)
Like
Declaration
public static bool Like(this string source, string pattern, char escapeChar)
Parameters
| Type | Name | Description |
|---|---|---|
| String | source | Source property |
| String | pattern | Like pattern |
| Char | escapeChar | Escape character |
Returns
| Type | Description |
|---|---|
| Boolean | Like result |
Exceptions
| Type | Condition |
|---|---|
| XDataRuntimeException | Like pattern can not be null or empty |