Class: SPARQL::Client::QueryElement
- Defined in:
- vendor/bundler/ruby/3.3.0/bundler/gems/sparql-client-464d3f76cfd5/lib/sparql/client.rb
Overview
A query element can be used as a component of a query. It may be initialized with a string, which is wrapped in an appropriate container depending on the type of QueryElement. Implements #to_s to property serialize when generating a SPARQL query.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#elements ⇒ Object
readonly
Returns the value of attribute elements.
Instance Method Summary collapse
-
#initialize(*args) ⇒ QueryElement
constructor
A new instance of QueryElement.
- #to_s ⇒ Object
Constructor Details
#initialize(*args) ⇒ QueryElement
Returns a new instance of QueryElement.
868 869 870 |
# File 'vendor/bundler/ruby/3.3.0/bundler/gems/sparql-client-464d3f76cfd5/lib/sparql/client.rb', line 868 def initialize(*args) @elements = args end |
Instance Attribute Details
#elements ⇒ Object (readonly)
Returns the value of attribute elements.
866 867 868 |
# File 'vendor/bundler/ruby/3.3.0/bundler/gems/sparql-client-464d3f76cfd5/lib/sparql/client.rb', line 866 def elements @elements end |
Instance Method Details
#to_s ⇒ Object
872 873 874 |
# File 'vendor/bundler/ruby/3.3.0/bundler/gems/sparql-client-464d3f76cfd5/lib/sparql/client.rb', line 872 def to_s raise NotImplemented end |