Class: SPARQL::Client::QueryElement

Inherits:
Object
  • Object
show all
Defined in:
vendor/bundler/ruby/2.6.0/bundler/gems/sparql-client-8b2723ff9503/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

SPARQL::Client::Query::Filter

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(*args) ⇒ QueryElement

Returns a new instance of QueryElement



823
824
825
# File 'vendor/bundler/ruby/2.6.0/bundler/gems/sparql-client-8b2723ff9503/lib/sparql/client.rb', line 823

def initialize(*args)
  @elements = args
end

Instance Attribute Details

#elementsObject (readonly)

Returns the value of attribute elements



821
822
823
# File 'vendor/bundler/ruby/2.6.0/bundler/gems/sparql-client-8b2723ff9503/lib/sparql/client.rb', line 821

def elements
  @elements
end

Instance Method Details

#to_sObject

Raises:

  • (NotImplemented)


827
828
829
# File 'vendor/bundler/ruby/2.6.0/bundler/gems/sparql-client-8b2723ff9503/lib/sparql/client.rb', line 827

def to_s
  raise NotImplemented
end