hasparql-client-0.1: This package enables to write SPARQL queries to remote endpoints.

Database.HaSparqlClient.Types

Contents

Description

Type definitions.

Synopsis

SELECT binding value

data BindingValue Source

Representation for SELECT query result format.

Constructors

URI String

URI reference to remote resource.

Literal String

Literal string without datatype or lang.

TypedLiteral String String

Literal with datatype URI.

LangLiteral String String

Literal with language.

BNode String

Blank Node with label.

Unbound

Unbound result value.

Instances

Eq BindingValue 
Show BindingValue 
ShowQuery BindingValue

SPARQL XML representation for BindingValue.

SPARQL service

data Service Source

Local representation for a SPARQL service.

Instances

Required elements

type Endpoint = StringSource

Represents a SPARQL endpoint.

type Query = StringSource

SPARQL query String.

Optional elements

type DefaultGraph = Maybe StringSource

Add a default graph URI. Overrides the default graph from SPARQL queries.

type NamedGraph = StringSource

Add a named graph URI. Overrides named graphs from SPARQL queries.

type ExtraParameters = (Key, Value)Source

Some SPARQL endpoints require extra key value pairs. E.g., in Virtuoso Server, one would add should-sponge=soft to the query forcing virtuoso to retrieve graphs that are not stored in its local database. Can be for example, used to try others output formats in RunQuery depending on the server.

type KeySource

Arguments

 = String

named-graph-uri and default-graph-uri keys not allowed here. They're removed.

key of the query part.

type Value = StringSource

value of the query part.

Request method

data Method Source

Set to HTTP GET or POST request, according to the SPARQL protocol, some endpoints do not yet support POST requests. Some SPARQL queries, perhaps machine generated, may be longer than can be reliably conveyed by way of the HTTP GET. In those cases the POST may be used.

Constructors

HGET 
HPOST 

Instances