Class: RDF::Query::Variable

Inherits:
Object show all
Includes:
SPARQL::Algebra::Expression
Defined in:
lib/sparql/algebra/extensions.rb

Overview

Extensions for RDF::Query::Variable.

Instance Method Summary collapse

Methods included from SPARQL::Algebra::Expression

cast, #constant?, for, new, open, #optimize, parse, #to_sse, #variable?

Instance Method Details

#evaluate(bindings = {}) ⇒ RDF::Term

Returns the value of this variable in the given bindings.

Parameters:

  • bindings (RDF::Query::Solution, #[]) (defaults to: {})

Returns:



217
218
219
# File 'lib/sparql/algebra/extensions.rb', line 217

def evaluate(bindings = {})
  bindings[name.to_sym]
end