datatype:
- prefixes : map from prefix => iri
- selects : list of variable names (with the question mark)
- wheres : list of triple patterns :=
- triple := subject predicate object (string string string)
- FILTER (filter_string)
- OPTIONAL (pattern, pattern)
- UNION (pattern, pattern)
- ORDER BY (asc/desc, variable/expression)
- LIMIT (integer)
- OFFSET (integer)
what kind of operators should there be?
what should happen in case of conflicts?
- always assume that the one on the left is right
Old ideas
At first the SPARQL queries were simply represented as strings.
Pros:
- simple/standard datatype
Cons:
- not as simple/standard to make complex manipulations to
Then use partial queries and some kind of data structure
Pros:
- easier to manipulate.
- easier to define operators
Cons:
- ?