Interface ISparqlNodeComparer
Interface for a comparer that can compare INode and IValuedNode instances.
Namespace: VDS.RDF.Query
Assembly: dotNetRdf.dll
Syntax
public interface ISparqlNodeComparer
Properties
| Edit this page View SourceCulture
Get the culture to use for string literal comparison.
Declaration
CultureInfo Culture { get; }
Property Value
| Type | Description |
|---|---|
| CultureInfo |
Options
Get the options to apply to string literal comparison.
Declaration
CompareOptions Options { get; }
Property Value
| Type | Description |
|---|---|
| CompareOptions |
Methods
| Edit this page View SourceTryCompare(INode, INode, out int)
Attempt to compare the specified nodes.
Declaration
bool TryCompare(INode x, INode y, out int result)
Parameters
| Type | Name | Description |
|---|---|---|
| INode | x | Node to be compared. |
| INode | y | Node to be compared. |
| int | result | Comparison result. |
Returns
| Type | Description |
|---|---|
| bool | True if a comparison could be made, false otherwise. |
Remarks
result is set to 0 if the nodes compare as equal, a positive value if x compares greater than y, or a negative value if y compares greater than x.
TryCompare(IValuedNode, IValuedNode, out int)
Attempt to compare the specified nodes.
Declaration
bool TryCompare(IValuedNode x, IValuedNode y, out int result)
Parameters
| Type | Name | Description |
|---|---|---|
| IValuedNode | x | Node to be compared. |
| IValuedNode | y | Node to be compared. |
| int | result | Comparison result. |
Returns
| Type | Description |
|---|---|
| bool | True if a comparison could be made, false otherwise. |
Remarks
result is set to 0 if the nodes compare as equal, a positive value if x compares greater than y, or a negative value if y compares greater than x.