aboutsummaryrefslogtreecommitdiffstats
path: root/lv2
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-09-09 05:34:59 +0000
committerDavid Robillard <d@drobilla.net>2012-09-09 05:34:59 +0000
commit762e323bef39d297fa19cfc3ef108f56e85a045d (patch)
tree901d6a5b40743b432dc85ed943e94c6775836cd3 /lv2
parent32d8a611c09b5a0f282e34ef89e8529e59e128e1 (diff)
downloadlv2-762e323bef39d297fa19cfc3ef108f56e85a045d.tar.xz
Use stricter datatype definitions conformant with the XSD and OWL specifications for better validation.
Diffstat (limited to 'lv2')
-rw-r--r--lv2/lv2plug.in/ns/lv2core/lv2core.ttl29
-rw-r--r--lv2/lv2plug.in/ns/meta/meta.ttl2
2 files changed, 19 insertions, 12 deletions
diff --git a/lv2/lv2plug.in/ns/lv2core/lv2core.ttl b/lv2/lv2plug.in/ns/lv2core/lv2core.ttl
index 2a8fc62..b923317 100644
--- a/lv2/lv2plug.in/ns/lv2core/lv2core.ttl
+++ b/lv2/lv2plug.in/ns/lv2core/lv2core.ttl
@@ -142,7 +142,7 @@ lv2:Plugin
rdfs:subClassOf [
a owl:Restriction ;
owl:onProperty doap:name ;
- owl:someValuesFrom xsd:string ;
+ owl:someValuesFrom rdf:PlainLiteral ;
rdfs:comment """
A Plugin MUST have at least one doap:name that is a string
with no language tag.
@@ -170,18 +170,18 @@ lv2:Port
rdfs:subClassOf [
a owl:Restriction ;
owl:onProperty lv2:index ;
- owl:allValuesFrom xsd:nonNegativeInteger ;
+ owl:allValuesFrom xsd:unsignedInt ;
owl:cardinality 1 ;
rdfs:comment """
-A port MUST have a single lv2:index which is of type xsd:nonNegativeInteger
-(e.g. a non-negative integer literal in Turtle). The actual RDF datatype
-of the index MAY be xsd:integer (which is what a generic Turtle parser
-will do), but the value itself MUST be non-negative.
+A port MUST have a single lv2:index which is of type xsd:unsignedInt. The
+explicit RDF datatype of the index MAY be something else (typically xsd:integer
+for pretty Turtle numeric literals), but the value itself MUST be a valid
+xsd:unsignedInt (i.e. a non-negative 32-bit integer).
"""
] , [
a owl:Restriction ;
owl:onProperty lv2:symbol ;
- owl:allValuesFrom xsd:string ;
+ owl:allValuesFrom rdf:PlainLiteral ;
owl:cardinality 1 ;
rdfs:comment """
A port MUST have a single lv2:symbol which is of type xsd:string with no
@@ -286,7 +286,8 @@ lv2:port
rdfs:comment "Relates a Plugin to the Ports it contains" .
lv2:project
- a rdf:Property ;
+ a rdf:Property ,
+ owl:ObjectProperty ;
rdfs:range doap:Project ;
rdfs:label "project" ;
lv2:documentation """
@@ -442,14 +443,18 @@ lv2:index
a rdf:Property ,
owl:DatatypeProperty ,
owl:FunctionalProperty ;
- rdfs:range xsd:nonNegativeInteger ;
+ rdfs:range xsd:unsignedInt ;
rdfs:label "index" ;
- rdfs:comment "A non-negative zero-based index." .
+ rdfs:comment "A non-negative zero-based 32-bit index." .
lv2:Symbol
a rdfs:Datatype ;
- rdfs:subClassOf xsd:string ;
- xsd:pattern "[_a-zA-Z][_a-zA-Z0-9]*$" ;
+ owl:onDatatype xsd:string ;
+ owl:withRestrictions (
+ [
+ xsd:pattern "[_a-zA-Z][_a-zA-Z0-9]*"
+ ]
+ ) ;
rdfs:comment """
A short restricted name used as a machine and human readable identifier.
diff --git a/lv2/lv2plug.in/ns/meta/meta.ttl b/lv2/lv2plug.in/ns/meta/meta.ttl
index 8fe5775..194418c 100644
--- a/lv2/lv2plug.in/ns/meta/meta.ttl
+++ b/lv2/lv2plug.in/ns/meta/meta.ttl
@@ -54,6 +54,8 @@ THIS SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH R
dcs:changeset [
dcs:item [
rdfs:label "Move all project metadata for extensions (e.g. change log) to separate files to spare hosts from loading them during discovery."
+ ] , [
+ rdfs:label "Use stricter datatype definitions conformant with the XSD and OWL specifications for better validation."
]
]
] , [