lib/activerdf_sparql-1.3.6/lib/activerdf_sparql/sparql.rb
def header(query)
    header = case @result_format
      when :json
      { 'accept' => 'application/sparql-results+json' }
      when :xml
      { 'accept' => 'application/rdf+xml' }
      when :sparql_xml
      { 'accept' => 'application/sparql-results+xml' }
    end
    if @auth
      header.merge( :http_basic_authentication => @auth )
    else
      header
    end
  end
# constructs correct HTTP header for selected query-result format
constructs correct HTTP header for selected query-result format
constructs correct HTTP header for selected query - result format
def header(query)
    header = case @result_format
      when :json
      { 'accept' => 'application/sparql-results+json' }
      when :xml
      { 'accept' => 'application/rdf+xml' }
      when :sparql_xml
      { 'accept' => 'application/sparql-results+xml' }
    end
    if @auth
      header.merge( :http_basic_authentication => @auth )
    else
      header
    end
  end
def header ( query ) header = case @result_format when :json { 'accept' => 'application/sparql-results+json' } when :xml { 'accept' => 'application/rdf+xml' } when :sparql_xml { 'accept' => 'application/sparql-results+xml' } end if @auth header . merge ( :http_basic_authentication => @auth ) else header end end
constructs correct HTTP header for selected query-result format
constructs correct HTTP header for selected query - result format
query