Class SparqlNodeComparer
Comparer class for implementing the SPARQL semantics for the relational operators.
Implements
Inherited Members
Namespace: VDS.RDF.Query
Assembly: dotNetRdf.dll
Syntax
public class SparqlNodeComparer : ISparqlNodeComparer
Constructors
| Improve this Doc View SourceSparqlNodeComparer(CultureInfo, CompareOptions)
Create a new comparer that will use the specified culture and options when comparing string literals.
Declaration
public SparqlNodeComparer(CultureInfo culture, CompareOptions options)
Parameters
Type | Name | Description |
---|---|---|
System.Globalization.CultureInfo | culture | The culture to use for string literal comparison. |
System.Globalization.CompareOptions | options | The options to apply to string literal comparison. |
Properties
| Improve this Doc View SourceCulture
Get the culture to use for string literal comparison.
Declaration
public CultureInfo Culture { get; }
Property Value
Type | Description |
---|---|
System.Globalization.CultureInfo |
Options
Get the options to apply to string literal comparison.
Declaration
public CompareOptions Options { get; }
Property Value
Type | Description |
---|---|
System.Globalization.CompareOptions |
Methods
| Improve this Doc View SourceBooleanCompare(INode, INode)
Declaration
protected virtual int BooleanCompare(INode x, INode y)
Parameters
Type | Name | Description |
---|---|---|
INode | x | |
INode | y |
Returns
Type | Description |
---|---|
int |
BooleanCompare(IValuedNode, IValuedNode)
Declaration
protected virtual int BooleanCompare(IValuedNode x, IValuedNode y)
Parameters
Type | Name | Description |
---|---|---|
IValuedNode | x | |
IValuedNode | y |
Returns
Type | Description |
---|---|
int |
Compare(INode, INode)
Compares two Nodes.
Declaration
[Obsolete("Replaced with bool TryCompare(INode, INode, out int)")]
public virtual int Compare(INode x, INode y)
Parameters
Type | Name | Description |
---|---|---|
INode | x | Node. |
INode | y | Node. |
Returns
Type | Description |
---|---|
int |
Compare(IValuedNode, IValuedNode)
Compares two valued Nodes.
Declaration
[Obsolete("Replaced with bool TryCompare(IValuedNode, IValuedNode, out int)")]
public virtual int Compare(IValuedNode x, IValuedNode y)
Parameters
Type | Name | Description |
---|---|---|
IValuedNode | x | Node. |
IValuedNode | y | Node. |
Returns
Type | Description |
---|---|
int |
DateCompare(INode, INode)
Compares two Dates for Date ordering.
Declaration
protected virtual int DateCompare(INode x, INode y)
Parameters
Type | Name | Description |
---|---|---|
INode | x | Node. |
INode | y | Node. |
Returns
Type | Description |
---|---|
int |
DateCompare(IValuedNode, IValuedNode)
Compares two Dates for Date ordering.
Declaration
protected virtual int DateCompare(IValuedNode x, IValuedNode y)
Parameters
Type | Name | Description |
---|---|---|
IValuedNode | x | Node. |
IValuedNode | y | Node. |
Returns
Type | Description |
---|---|
int |
DateTimeCompare(INode, INode)
Compares two Date Times for Date Time ordering.
Declaration
protected virtual int DateTimeCompare(INode x, INode y)
Parameters
Type | Name | Description |
---|---|---|
INode | x | Node. |
INode | y | Node. |
Returns
Type | Description |
---|---|
int |
DateTimeCompare(IValuedNode, IValuedNode)
Compares two Date Times for Date Time ordering.
Declaration
protected virtual int DateTimeCompare(IValuedNode x, IValuedNode y)
Parameters
Type | Name | Description |
---|---|---|
IValuedNode | x | Node. |
IValuedNode | y | Node. |
Returns
Type | Description |
---|---|
int |
NumericCompare(INode, INode, SparqlNumericType)
Compares two Nodes for Numeric Ordering.
Declaration
protected virtual int NumericCompare(INode x, INode y, SparqlNumericType type)
Parameters
Type | Name | Description |
---|---|---|
INode | x | Node. |
INode | y | Node. |
SparqlNumericType | type | Numeric Type. |
Returns
Type | Description |
---|---|
int |
NumericCompare(IValuedNode, IValuedNode, SparqlNumericType)
Compares two Nodes for Numeric Ordering.
Declaration
protected virtual int NumericCompare(IValuedNode x, IValuedNode y, SparqlNumericType type)
Parameters
Type | Name | Description |
---|---|---|
IValuedNode | x | Node. |
IValuedNode | y | Node. |
SparqlNumericType | type | Numeric Type. |
Returns
Type | Description |
---|---|
int |
TryCompare(INode, INode, out int)
Declaration
public bool TryCompare(INode x, INode y, out int result)
Parameters
Type | Name | Description |
---|---|---|
INode | x | |
INode | y | |
int | result |
Returns
Type | Description |
---|---|
System.Boolean |
TryCompare(IValuedNode, IValuedNode, out int)
Declaration
public bool TryCompare(IValuedNode x, IValuedNode y, out int result)
Parameters
Type | Name | Description |
---|---|---|
IValuedNode | x | |
IValuedNode | y | |
int | result |
Returns
Type | Description |
---|---|
System.Boolean |