From 4a8194336ac51ff9fb84c2cbc07000c8b0e4d981 Mon Sep 17 00:00:00 2001 From: Sam Thursfield Date: Tue, 30 Jun 2015 15:10:51 +0100 Subject: schema: Add some bits that were missing Change-Id: I060c077e286cf3203e61d72851d165c10ab2ead3 --- schema/baserock-owl-schema.turtle | 102 ++++++++++++++++++++++++++++++++++---- 1 file changed, 92 insertions(+), 10 deletions(-) diff --git a/schema/baserock-owl-schema.turtle b/schema/baserock-owl-schema.turtle index b89a0aa6..42dafba8 100644 --- a/schema/baserock-owl-schema.turtle +++ b/schema/baserock-owl-schema.turtle @@ -22,7 +22,7 @@ # comments and formatting. -## Entities +# Metadata @prefix : . @prefix owl: . @@ -30,23 +30,43 @@ @prefix rdf: . @prefix xsd: . +: a owl:Ontology ; + rdfs:comment "Example schema for Baserock Definitions format version 5." . + + +## Entities + +# Source definitions + :Morphology a owl:Class . :Cluster a owl:Class ; - rdfs:subClassOf :morphology . - -:SystemDeployment a owl:Class . + rdfs:subClassOf :Morphology . :System a owl:Class ; - rdfs:subClassOf :morphology . + rdfs:subClassOf :Morphology . :Stratum a owl:Class ; + rdfs:subClassOf :Morphology . + +:Chunk a owl:Class ; rdfs:subClassOf :morphology . +# Container contents + +:SystemDeployment a owl:Class . + :ChunkReference a owl:Class . -:Chunk a owl:Class ; - rdfs:subClassOf :morphology . +# Products (for artifact split rules). + +:Artifact a owl:Class . + +:StratumArtifact a owl:Class ; + rdfs:subClassOf :Artifact . + +:ChunkArtifact a owl:Class ; + rdfs:subClassOf :Artifact . ## Shared properties @@ -93,9 +113,9 @@ ## System-specific properties -:containsStratum a owl:ObjectProperty ; +:containsStratumArtifact a owl:ObjectProperty ; rdfs:domain :System ; - rdfs:range :Stratum . + rdfs:range :StratumArtifact . :hasArchitecture a owl:DatatypeProperty, owl:FunctionalProperty ; rdfs:domain :System ; @@ -108,6 +128,10 @@ ## Stratum-specific properties +:produces a owl:ObjectProperty , rdf:Seq ; + rdfs:domain :Stratum ; + rdfs:range :StratumArtifact . + :hasStratumBuildDependency a owl:ObjectProperty ; rdfs:domain :Stratum ; rdfs:range :Stratum . @@ -139,10 +163,68 @@ rdfs:domain :ChunkReference ; rdfs:range :Chunk . +:prefix a owl:DatatypeProperty , owl:FunctionalProperty ; + rdfs:domain :ChunkReference ; + rdfs:range xsd:string . + +# FIXME: actually only 'bootstrap' and 'normal' are valid values. +:buildMode a owl:DatatypeProperty , owl:FunctionalProperty ; + rdfs:domain :ChunkReference ; + rdfs:range xsd:string . + ## Chunk-specific properties # build-system isn't included here, as it overlaps with the *-commands # fields in an unfortunate way. -# FIXME: how do you do lists ?? +# Note that representing lists of things in RDF is a bit of a pain. +# http://smiy.sourceforge.net/olo/spec/orderedlistontology.html might +# be worth investigating. + +:produces a owl:ObjectProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range :ChunkArtifact . + +:preConfigureCommands a owl:DatatypeProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range xsd:string . + +:configureCommands a owl:DatatypeProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range xsd:string . + +:postConfigureCommands a owl:DatatypeProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range xsd:string . + +:preBuildCommands a owl:DatatypeProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range xsd:string . + +:buildCommands a owl:DatatypeProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range xsd:string . + +:postBuildCommands a owl:DatatypeProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range xsd:string . + +:preInstallCommands a owl:DatatypeProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range xsd:string . + +:installCommands a owl:DatatypeProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range xsd:string . + +:postInstallCommands a owl:DatatypeProperty , rdf:Seq ; + rdfs:domain :Chunk ; + rdfs:range xsd:string . + + +# Artifact properties + +:includes a owl:DatatypeProperty, rdf:Seq ; + rdfs:domain :Artifact ; + rdfs:range xsd:string . -- cgit v1.2.1