SPIN_EP-queries.spin.ttl 3.05 KB
# baseURI: http://www.reportinghub.no/ep/spin/queries
# imports: http://spinrdf.org/spin
# imports: http://www.reportinghub.no/ep/schema/1.0/ddr

@prefix owl:     <http://www.w3.org/2002/07/owl#> .
@prefix queries:  <http://www.reportinghub.no/ep/spin/queries#> .
@prefix rdf:     <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs:    <http://www.w3.org/2000/01/rdf-schema#> .
@prefix sp:      <http://spinrdf.org/sp#> .
@prefix spin:    <http://spinrdf.org/spin#> .
@prefix spl:     <http://spinrdf.org/spl#> .
@prefix xsd:     <http://www.w3.org/2001/XMLSchema#> .

<http://spinrdf.org/arg#arg1>
      rdf:type rdf:Property ;
      rdfs:label "arg1"^^xsd:string ;
      rdfs:subPropertyOf sp:arg .

<http://spinrdf.org/arg#arg2>
      rdf:type rdf:Property ;
      rdfs:label "arg2"^^xsd:string ;
      rdfs:subPropertyOf sp:arg .

<http://spinrdf.org/arg#arg3>
      rdf:type rdf:Property ;
      rdfs:label "arg3"^^xsd:string ;
      rdfs:subPropertyOf sp:arg .

<http://www.reportinghub.no/ep/spin/queries>
      rdf:type owl:Ontology ;
      owl:imports <http://spinrdf.org/spin> , <http://www.reportinghub.no/ep/schema/1.0/ddr> ;
      owl:versionInfo "Created with TopBraid Composer"^^xsd:string .

queries:TestQuery1
      rdf:type spin:SelectTemplate ;
      rdfs:label "Test query 1"^^xsd:string ;
      rdfs:subClassOf spin:SelectTemplates ;
      spin:body
              [ rdf:type sp:Select ;
                sp:resultVariables (spin:_arg1 spin:_arg2 spin:_arg3) ;
                sp:where ()
              ] ;
      spin:constraint
              [ rdf:type spl:Argument ;
                rdfs:comment "An optional integer value."^^xsd:string ;
                spl:optional "true"^^xsd:boolean ;
                spl:predicate <http://spinrdf.org/arg#arg3> ;
                spl:valueType xsd:integer
              ] ;
      spin:constraint
              [ rdf:type spl:Argument ;
                rdfs:comment "A float value"^^xsd:string ;
                spl:predicate <http://spinrdf.org/arg#arg2> ;
                spl:valueType xsd:float
              ] ;
      spin:constraint
              [ rdf:type spl:Argument ;
                rdfs:comment "A string argument"^^xsd:string ;
                spl:predicate <http://spinrdf.org/arg#arg1> ;
                spl:valueType xsd:string
              ] .

queries:TestQuery2
      rdf:type spin:SelectTemplate ;
      rdfs:label "Test query 2"^^xsd:string ;
      rdfs:subClassOf spin:SelectTemplates ;
      spin:body
              [ rdf:type sp:Select ;
                sp:resultVariables (spin:_arg1 spin:_arg2) ;
                sp:where ()
              ] ;
      spin:constraint
              [ rdf:type spl:Argument ;
                rdfs:comment "A string argument"^^xsd:string ;
                spl:predicate <http://spinrdf.org/arg#arg1> ;
                spl:valueType xsd:string
              ] ;
      spin:constraint
              [ rdf:type spl:Argument ;
                rdfs:comment "A float value"^^xsd:string ;
                spl:predicate <http://spinrdf.org/arg#arg2> ;
                spl:valueType xsd:float
              ] .