PizzaTopping

IRI: http://draft.ottr.xyz/pizza/PizzaTopping

Available formats

Specification

@prefix : <http://draft.ottr.xyz/pizza/PizzaTopping#> .
@prefix p: <http://www.co-ode.org/ontologies/pizza/pizza.owl#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix skos: <http://www.w3.org/2004/02/skos/core#> .
@prefix t-owl-axiom: <http://candidate.ottr.xyz/owl/axiom/> .
@prefix t-rdf: <http://candidate.ottr.xyz/rdf/> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

http://draft.ottr.xyz/pizza/PizzaTopping( :subject : 1 class , <"label"^^xsd:string> : + list , "prefLabel"^^xsd:string : 1 literal , <"comment"^^xsd:string> : * list , :spiciness : ? nonLiteral )
  ::
  t-owl-axiom:SubClassOf( :subject , p:PizzaTopping )
  t-owl-axiom:SubObjectSomeValuesFrom( :subject , p:hasSpiciness , :spiciness )
  X  | t-rdf:Triple( :subject , rdfs:comment , <"comment"^^xsd:string> )
  t-rdf:Triple( :subject , skos:prefLabel , "preflabel"^^xsd:string )
  X  | t-rdf:Triple( :subject , rdfs:label , <"label"^^xsd:string> ) .

Direct dependency templates

Templates instantiated in the body of this template:

Diagram of pattern

RDF graph visualisation of the expanded body:

Pattern

The pattern the template represents, i.e., the expanded template body.

@prefix p:     <http://www.co-ode.org/ontologies/pizza/pizza.owl#> .
@prefix :      <http://draft.ottr.xyz/pizza/PizzaTopping#> .
@prefix rdf:   <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix owl:   <http://www.w3.org/2002/07/owl#> .
@prefix skos:  <http://www.w3.org/2004/02/skos/core#> .
@prefix rdfs:  <http://www.w3.org/2000/01/rdf-schema#> .

:spiciness  a   owl:Class .

p:hasSpiciness  a  owl:ObjectProperty .

:subject  rdfs:comment   "comment" ;
        rdfs:label       "label" ;
        rdfs:subClassOf  p:PizzaTopping ;
        rdfs:subClassOf  [ a                   owl:Restriction ;
                           owl:onProperty      p:hasSpiciness ;
                           owl:someValuesFrom  :spiciness
                         ] ;
        skos:prefLabel   "preflabel" .

Source

Raw source - http://draft.ottr.xyz/pizza/PizzaTopping:

@prefix rdf:         <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs:        <http://www.w3.org/2000/01/rdf-schema#> .
@prefix skos:        <http://www.w3.org/2004/02/skos/core#> .

@prefix t-owl-axiom: <http://candidate.ottr.xyz/owl/axiom/> .
@prefix ottr:        <http://ns.ottr.xyz/templates#> .
@prefix t-rdf: <http://candidate.ottr.xyz/rdf/> .

@prefix p:           <http://www.co-ode.org/ontologies/pizza/pizza.owl#> .
@prefix :            <http://draft.ottr.xyz/pizza/PizzaTopping#> .

<http://draft.ottr.xyz/pizza/PizzaTopping> a ottr:Template ;
  ottr:hasParameter
    [ ottr:index 1; ottr:classVariable :subject ] ,
    [ ottr:index 2; ottr:listVariable ( "label" ) ], 
    [ ottr:index 3; ottr:literalVariable "prefLabel" ] ,
    [ ottr:index 4; ottr:listVariable  ( "comment" ) ; ottr:optional true ],
    [ ottr:index 5; ottr:nonLiteralVariable :spiciness ; ottr:optional true ] .

[] ottr:templateRef t-owl-axiom:SubClassOf ;
   ottr:hasArgument
	[ ottr:index 1; ottr:value :subject ] ,
	[ ottr:index 2; ottr:value p:PizzaTopping ] .

[] ottr:templateRef t-rdf:Triple ;
   ottr:hasArgument
	[ ottr:index 1; ottr:value :subject ] ,
	[ ottr:index 2; ottr:value rdfs:label ] ,
	[ ottr:index 3; ottr:eachValue ( "label" ) ] .

[] ottr:templateRef t-rdf:Triple ;
   ottr:hasArgument
	[ ottr:index 1; ottr:value :subject ] ,
	[ ottr:index 2; ottr:value skos:prefLabel ] ,
	[ ottr:index 3; ottr:value "preflabel" ] .

[] ottr:templateRef t-rdf:Triple ;
   ottr:hasArgument
	[ ottr:index 1; ottr:value :subject ] ,
	[ ottr:index 2; ottr:value rdfs:comment ] ,
	[ ottr:index 3; ottr:eachValue ( "comment" ) ] .

[] ottr:templateRef t-owl-axiom:SubObjectSomeValuesFrom ;
   ottr:hasArgument
	[ ottr:index 1; ottr:value :subject ] ,
	[ ottr:index 2; ottr:value p:hasSpiciness ] ,
	[ ottr:index 3; ottr:value :spiciness ] .