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

Aus CTS2-LE
Zur Navigation springen Zur Suche springen
Zeile 41: Zeile 41:
 
::<code>Cardinality: 0..1</code>
 
::<code>Cardinality: 0..1</code>
 
:<code>mappingSpec</code>
 
:<code>mappingSpec</code>
::TODO
+
::json string of form {designations: [{propertyRegex: <code>p</code>, languageSelector: <code>s</code>, role: <code>r</code>}]} where <code>p</code> is an regex, <code>s</code> is an integer or '@' and <code>role</code> matching regex (PREFERRED)|(ALTERNATIVE) <br> semantics: Let (R, P, L) be a triple. For R whose local name of P matches <code>p</code> a designation with value L is added. If <code>s</code> is '@' then the designation language is the lang tag of L. If <code>s</code> is integer i then the lang tag is the content of the i-th capturing group of <code>p</code>. <code>r</code> is the role of the designation.
 
::<code>Cardinality: 0..1</code>
 
::<code>Cardinality: 0..1</code>
  

Version vom 12. Oktober 2016, 19:30 Uhr

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
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 or '@' and role matching regex (PREFERRED)|(ALTERNATIVE)
semantics: Let (R, P, L) be a triple. For R whose local name of P matches p a designation 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 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.