CTS2-LE REST API: OWL Update: Unterschied zwischen den Versionen

Aus CTS2-LE
Zur Navigation springen Zur Suche springen
(Operation Syntax)
Zeile 1: Zeile 1:
 +
Updates an OWL ontology. If the ontology does not exist, it is created. The ontology is mapped to a code system version of the CTS2 information model.
 +
 
== Operation Syntax ==
 
== Operation Syntax ==
 
Updates an OWL ontology. If the ontology does not exist, it is created. The ontology is mapped to a code system version of the CTS2 information model.
 
  
 
;Signature
 
;Signature

Version vom 12. Oktober 2016, 20:38 Uhr

Updates an OWL ontology. If the ontology does not exist, it is created. The ontology is mapped to a code system version of the CTS2 information model.

Operation Syntax

Signature
Response webCts2Le.service.crud.OwlResource.update(
@QueryParam(value="uri") String uri,
@QueryParam(value="version") String version,
@QueryParam(value="isDefaultVersion") @DefaultValue(value="true") boolean isDefaultVersion,
@QueryParam(value="resourceId") String resourceId,
@QueryParam(value="groupName") String groupName,
@QueryParam(value="defaultLanguage") @DefaultValue(value="en") String defaultLanguage,
@QueryParam(value="mappingSpec") String mappingSpec)
@POST
@Path(value="/service/crud/owl/update")
@Consumes(value={"application/xml"})
@Produces(value={"application/xml"})


Parameters
uri
uri of the ontology. Note that the pair (uri, version) uniquely defines a code system version within CTS2-LE
Cardinality: 1..1
version
version of the ontology
Cardinality: 1..1
isDefaultVersion
store as default version
Cardinality: 0..1
resourceId
unique CTS2-LE identifier (not an URI) of the code system version (also displayed in the navigator)
Cardinality: 1..1
groupName
group corresponding to the terminology tree in the navigator
Cardinality: 0..1
defaultLanguage
default language of the code system version
Cardinality: 0..1
mappingSpec
json string of form {designations: [{propertyRegex: p, languageSelector: s, role: r},...]} where p is an regex, s is an integer (as quoted string) or '@' and role matching regex (PREFERRED)|(ALTERNATIVE).
semantics: Let (R, P, L) be a triple. If local name of P matches p then a designation for R with value L is added. If s is '@' then the designation language is the lang tag of L. If s is integer i then the lang tag is the the lower case content of the i-th capturing group of p. r is the role of the designation.
Cardinality: 0..1


Consumed POST Body

OWL stream.

Cardinality: 1..1
Result
empty response if no error occurs otherwise an error XML.
Example
http://{{host_port}}/WebCts2LE/service/crud/owl/update
?uri=http://www.fao.org/countryprofiles/geoinfo/geopolitical/resource
&version=1.1
&resourceId=FAO-Geopolitical-ontology
&groupName=DEMIS2
&mappingSpec={designations: [{propertyRegex: 'nameOfficial(.*)', languageSelector: '1', role: 'PREFERRED'}]}