Class BindPattern
Class for representing BIND assignments in SPARQL Queries.
Implements
Inherited Members
Namespace: VDS.RDF.Query.Patterns
Assembly: dotNetRdf.dll
Syntax
public class BindPattern : BaseTriplePattern, IComparable<BindPattern>, IAssignmentPattern, ITriplePattern, IComparable<ITriplePattern>, IProcessable, IVisitable, IComparable<IAssignmentPattern>
Constructors
| Edit this page View SourceBindPattern(string, ISparqlExpression)
Creates a new BIND Pattern.
Declaration
public BindPattern(string var, ISparqlExpression expr)
Parameters
| Type | Name | Description |
|---|---|---|
| string | var | Variable to assign to. |
| ISparqlExpression | expr | Expression which generates a value which will be assigned to the variable. |
Properties
| Edit this page View SourceAssignExpression
Gets the Expression that is used to generate values to be assigned.
Declaration
public ISparqlExpression AssignExpression { get; }
Property Value
| Type | Description |
|---|---|
| ISparqlExpression |
FixedVariables
Returns an empty enumeration as any evaluation error will result in an unbound value so we can't guarantee any variables are bound.
Declaration
public override IEnumerable<string> FixedVariables { get; }
Property Value
| Type | Description |
|---|---|
| IEnumerable<string> |
Overrides
| Edit this page View SourceFloatingVariables
Returns the variable being assigned to as any evaluation error will result in an unbound value so we can't guarantee it is bound.
Declaration
public override IEnumerable<string> FloatingVariables { get; }
Property Value
| Type | Description |
|---|---|
| IEnumerable<string> |
Overrides
| Edit this page View SourceHasNoBlankVariables
Returns true as a BIND can never contain a Blank Variable.
Declaration
public override bool HasNoBlankVariables { get; }
Property Value
| Type | Description |
|---|---|
| bool |
Overrides
| Edit this page View SourceInnerExpression
Get the expressions which generates a value to be assigned to the variable.
Declaration
public ISparqlExpression InnerExpression { get; }
Property Value
| Type | Description |
|---|---|
| ISparqlExpression |
IsAcceptAll
Returns that this is not an accept all since it is a BIND assignment.
Declaration
public override bool IsAcceptAll { get; }
Property Value
| Type | Description |
|---|---|
| bool |
Overrides
| Edit this page View SourcePatternType
Gets the Pattern Type.
Declaration
public override TriplePatternType PatternType { get; }
Property Value
| Type | Description |
|---|---|
| TriplePatternType |
Overrides
| Edit this page View SourceUsesDefaultDataset
Gets whether the Pattern uses the Default Dataset.
Declaration
public override bool UsesDefaultDataset { get; }
Property Value
| Type | Description |
|---|---|
| bool |
Overrides
| Edit this page View SourceVariable
Get the variable to assign to.
Declaration
public string Variable { get; }
Property Value
| Type | Description |
|---|---|
| string |
VariableName
Gets the Name of the Variable to which values will be assigned.
Declaration
public string VariableName { get; }
Property Value
| Type | Description |
|---|---|
| string |
Methods
| Edit this page View SourceAccept<T>(ISparqlAlgebraVisitor<T>)
Accept a simple algebra visitor.
Declaration
public override T Accept<T>(ISparqlAlgebraVisitor<T> visitor)
Parameters
| Type | Name | Description |
|---|---|---|
| ISparqlAlgebraVisitor<T> | visitor | The visitor implementation. |
Returns
| Type | Description |
|---|---|
| T |
Type Parameters
| Name | Description |
|---|---|
| T | The type returned by the Visit methods of the visitor. |
Overrides
| Edit this page View SourceAccept<TResult, TContext>(ISparqlQueryAlgebraProcessor<TResult, TContext>, TContext)
Called by an algebra visitor to process an item by invoking the appropriate method on the processor passed in.
Declaration
public override TResult Accept<TResult, TContext>(ISparqlQueryAlgebraProcessor<TResult, TContext> processor, TContext context)
Parameters
| Type | Name | Description |
|---|---|---|
| ISparqlQueryAlgebraProcessor<TResult, TContext> | processor | The processor to invoke. |
| TContext | context | The context to pass to the processor. |
Returns
| Type | Description |
|---|---|
| TResult | The result of invoking the processor method. |
Type Parameters
| Name | Description |
|---|---|
| TResult | The type of result returned by the processor. |
| TContext | The type of the context object to be provided to the processor. |
Overrides
| Edit this page View SourceCompareTo(BindPattern)
Compares this Bind to another Bind.
Declaration
public int CompareTo(BindPattern other)
Parameters
| Type | Name | Description |
|---|---|---|
| BindPattern | other | Bind to compare to. |
Returns
| Type | Description |
|---|---|
| int | Just calls the base compare method since that implements all the logic we need. |
CompareTo(IAssignmentPattern)
Compares this Bind to another Bind.
Declaration
public int CompareTo(IAssignmentPattern other)
Parameters
| Type | Name | Description |
|---|---|---|
| IAssignmentPattern | other | Bind to compare to. |
Returns
| Type | Description |
|---|---|
| int | Just calls the base compare method since that implements all the logic we need. |
ToString()
Gets the string representation of the LET assignment.
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| string |