@prefix fhir: <http://hl7.org/fhir/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

# - resource -------------------------------------------------------------------

<http://hl7.org/cda/stds/core/StructureDefinition/cs-simple> a fhir:StructureDefinition ;
  fhir:nodeRole fhir:treeRoot ;
  fhir:id [ fhir:v "cs-simple"] ; # 
  fhir:text [
     fhir:status [ fhir:v "generated" ] ;
     fhir:div [ fhir:v "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n      <p>Primitive type 'cs'</p>\n    </div>"^^rdf:XMLLiteral ]
  ] ; # 
  fhir:extension ( [
     fhir:url [
       fhir:v "http://hl7.org/fhir/tools/StructureDefinition/xml-namespace"^^xsd:anyURI ;
       fhir:l <http://hl7.org/fhir/tools/StructureDefinition/xml-namespace>
     ] ;
     fhir:value [
       a fhir:Uri ;
       fhir:v "urn:hl7-org:v3"^^xsd:anyURI ;
       fhir:l <urn:hl7-org:v3>
     ]
  ] [
     fhir:url [
       fhir:v "http://hl7.org/fhir/StructureDefinition/structuredefinition-type-characteristics"^^xsd:anyURI ;
       fhir:l <http://hl7.org/fhir/StructureDefinition/structuredefinition-type-characteristics>
     ] ;
     fhir:value [
       a fhir:Code ;
       fhir:v "can-bind"
     ]
  ] [
     fhir:url [
       fhir:v "http://hl7.org/fhir/tools/StructureDefinition/logical-container"^^xsd:anyURI ;
       fhir:l <http://hl7.org/fhir/tools/StructureDefinition/logical-container>
     ] ;
     fhir:value [
       a fhir:Uri ;
       fhir:v "http://hl7.org/cda/stds/core/StructureDefinition/ClinicalDocument"^^xsd:anyURI ;
       fhir:l <http://hl7.org/cda/stds/core/StructureDefinition/ClinicalDocument>
     ]
  ] ) ; # 
  fhir:url [
     fhir:v "http://hl7.org/cda/stds/core/StructureDefinition/cs-simple"^^xsd:anyURI ;
     fhir:l <http://hl7.org/cda/stds/core/StructureDefinition/cs-simple>
  ] ; # 
  fhir:version [ fhir:v "2.0.3-sd"] ; # 
  fhir:name [ fhir:v "cs"] ; # 
  fhir:title [ fhir:v "cs: Coded Simple Value"] ; # 
  fhir:status [ fhir:v "active"] ; # 
  fhir:experimental [ fhir:v false] ; # 
  fhir:date [ fhir:v "2026-06-12T07:06:38+10:00"^^xsd:dateTime] ; # 
  fhir:publisher [ fhir:v "Health Level 7"] ; # 
  fhir:contact ( [
     fhir:name [ fhir:v "HL7 International - Structured Documents" ] ;
     fhir:telecom ( [
       fhir:system [ fhir:v "url" ] ;
       fhir:value [ fhir:v "http://www.hl7.org/Special/committees/structure" ]
     ] [
       fhir:system [ fhir:v "email" ] ;
       fhir:value [ fhir:v "structdog@lists.HL7.org" ]
     ] )
  ] ) ; # 
  fhir:description [ fhir:v "Coded data in its simplest form, consists of a code. The code system and code system version is fixed by the context in which the value occurs. 'cs' is used for coded attributes that have a single HL7-defined value set."] ; # 
  fhir:fhirVersion [ fhir:v "5.0.0"] ; # 
  fhir:kind [ fhir:v "primitive-type"] ; # 
  fhir:abstract [ fhir:v false] ; # 
  fhir:type [
     fhir:v "code"^^xsd:anyURI ;
     fhir:l fhir:code
  ] ; # 
  fhir:baseDefinition [
     fhir:v "http://hl7.org/fhir/StructureDefinition/code"^^xsd:anyURI ;
     fhir:l <http://hl7.org/fhir/StructureDefinition/code>
  ] ; # 
  fhir:derivation [ fhir:v "constraint"] ; # 
  fhir:snapshot [
     fhir:extension ( [
       fhir:url [
         fhir:v "http://hl7.org/fhir/tools/StructureDefinition/snapshot-base-version"^^xsd:anyURI ;
         fhir:l <http://hl7.org/fhir/tools/StructureDefinition/snapshot-base-version>
       ] ;
       fhir:value [
         a fhir:String ;
         fhir:v "5.0.0"
       ]
     ] ) ;
     fhir:element ( [
       fhir:id [ fhir:v "code" ] ;
       fhir:path [ fhir:v "code" ] ;
       fhir:short [ fhir:v "Primitive Type code" ] ;
       fhir:definition [ fhir:v "A string which has at least one character and no leading or trailing whitespace and where there is no whitespace other than single spaces in the contents" ] ;
       fhir:min [ fhir:v "0"^^xsd:nonNegativeInteger ] ;
       fhir:max [ fhir:v "*" ] ;
       fhir:base [
         fhir:path [ fhir:v "code" ] ;
         fhir:min [ fhir:v "0"^^xsd:nonNegativeInteger ] ;
         fhir:max [ fhir:v "*" ]
       ] ;
       fhir:constraint ( [
         fhir:key [ fhir:v "ele-1" ] ;
         fhir:severity [ fhir:v "error" ] ;
         fhir:human [ fhir:v "All FHIR elements must have a @value or children" ] ;
         fhir:expression [ fhir:v "hasValue() or (children().count() > id.count())" ] ;
         fhir:source [
           fhir:v "http://hl7.org/fhir/StructureDefinition/Element"^^xsd:anyURI ;
           fhir:l <http://hl7.org/fhir/StructureDefinition/Element>
         ]
       ] [
         fhir:key [ fhir:v "cs-pattern" ] ;
         fhir:severity [ fhir:v "error" ] ;
         fhir:human [ fhir:v "cs attributes must not contain any whitespace" ] ;
         fhir:expression [ fhir:v "matches('^[^\\\\s]+$')" ]
       ] ) ;
       fhir:isModifier [ fhir:v false ] ;
       fhir:isSummary [ fhir:v false ]
     ] [
       fhir:id [ fhir:v "code.id" ] ;
       fhir:path [ fhir:v "code.id" ] ;
       fhir:representation ( [ fhir:v "xmlAttr" ] ) ;
       fhir:short [ fhir:v "xml:id (or equivalent in JSON)" ] ;
       fhir:definition [ fhir:v "unique id for the element within a resource (for internal references)" ] ;
       fhir:min [ fhir:v "0"^^xsd:nonNegativeInteger ] ;
       fhir:max [ fhir:v "0" ] ;
       fhir:base [
         fhir:path [ fhir:v "Element.id" ] ;
         fhir:min [ fhir:v "0"^^xsd:nonNegativeInteger ] ;
         fhir:max [ fhir:v "1" ]
       ] ;
       fhir:type ( [
         fhir:extension ( [
           fhir:url [
             fhir:v "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type"^^xsd:anyURI ;
             fhir:l <http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type>
           ] ;
           fhir:value [
             a fhir:Url ;
             fhir:v "string"^^xsd:anyURI ;
             fhir:l fhir:string
           ]
         ] ) ;
         fhir:code [
           fhir:v "http://hl7.org/fhirpath/System.String"^^xsd:anyURI ;
           fhir:l <http://hl7.org/fhirpath/System.String>
         ]
       ] ) ;
       fhir:isModifier [ fhir:v false ] ;
       fhir:isSummary [ fhir:v false ]
     ] [
       fhir:id [ fhir:v "code.extension" ] ;
       fhir:path [ fhir:v "code.extension" ] ;
       fhir:short [ fhir:v "Extension" ] ;
       fhir:definition [ fhir:v "An Extension" ] ;
       fhir:min [ fhir:v "0"^^xsd:nonNegativeInteger ] ;
       fhir:max [ fhir:v "0" ] ;
       fhir:base [
         fhir:path [ fhir:v "Element.extension" ] ;
         fhir:min [ fhir:v "0"^^xsd:nonNegativeInteger ] ;
         fhir:max [ fhir:v "*" ]
       ] ;
       fhir:type ( [
         fhir:code [
           fhir:v "Extension"^^xsd:anyURI ;
           fhir:l fhir:Extension
         ]
       ] ) ;
       fhir:constraint ( [
         fhir:key [ fhir:v "ele-1" ] ;
         fhir:severity [ fhir:v "error" ] ;
         fhir:human [ fhir:v "All FHIR elements must have a @value or children" ] ;
         fhir:expression [ fhir:v "hasValue() or (children().count() > id.count())" ] ;
         fhir:source [
           fhir:v "http://hl7.org/fhir/StructureDefinition/Element"^^xsd:anyURI ;
           fhir:l <http://hl7.org/fhir/StructureDefinition/Element>
         ]
       ] [
         fhir:key [ fhir:v "ext-1" ] ;
         fhir:severity [ fhir:v "error" ] ;
         fhir:human [ fhir:v "Must have either extensions or value[x], not both" ] ;
         fhir:expression [ fhir:v "extension.exists() != value.exists()" ] ;
         fhir:source [
           fhir:v "http://hl7.org/fhir/StructureDefinition/Extension"^^xsd:anyURI ;
           fhir:l <http://hl7.org/fhir/StructureDefinition/Extension>
         ]
       ] ) ;
       fhir:isModifier [ fhir:v false ] ;
       fhir:isSummary [ fhir:v false ]
     ] [
       fhir:id [ fhir:v "code.value" ] ;
       fhir:path [ fhir:v "code.value" ] ;
       fhir:representation ( [ fhir:v "xmlAttr" ] ) ;
       fhir:short [ fhir:v "Primitive value for code" ] ;
       fhir:definition [ fhir:v "Primitive value for code" ] ;
       fhir:min [ fhir:v "0"^^xsd:nonNegativeInteger ] ;
       fhir:max [ fhir:v "1" ] ;
       fhir:base [
         fhir:path [ fhir:v "string.value" ] ;
         fhir:min [ fhir:v "0"^^xsd:nonNegativeInteger ] ;
         fhir:max [ fhir:v "1" ]
       ] ;
       fhir:type ( [
         fhir:extension ( [
           fhir:url [
             fhir:v "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type"^^xsd:anyURI ;
             fhir:l <http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type>
           ] ;
           fhir:value [
             a fhir:Url ;
             fhir:v "code"^^xsd:anyURI ;
             fhir:l fhir:code
           ]
         ] [
           fhir:url [
             fhir:v "http://hl7.org/fhir/StructureDefinition/regex"^^xsd:anyURI ;
             fhir:l <http://hl7.org/fhir/StructureDefinition/regex>
           ] ;
           fhir:value [
             a fhir:String ;
             fhir:v "[^\\s]+( [^\\s]+)*"
           ]
         ] ) ;
         fhir:code [
           fhir:v "http://hl7.org/fhirpath/System.String"^^xsd:anyURI ;
           fhir:l <http://hl7.org/fhirpath/System.String>
         ]
       ] ) ;
       fhir:isModifier [ fhir:v false ] ;
       fhir:isSummary [ fhir:v false ]
     ] )
  ] ; # 
  fhir:differential [
     fhir:element ( [
       fhir:id [ fhir:v "code" ] ;
       fhir:path [ fhir:v "code" ] ;
       fhir:constraint ( [
         fhir:key [ fhir:v "cs-pattern" ] ;
         fhir:severity [ fhir:v "error" ] ;
         fhir:human [ fhir:v "cs attributes must not contain any whitespace" ] ;
         fhir:expression [ fhir:v "matches('^[^\\\\s]+$')" ]
       ] )
     ] [
       fhir:id [ fhir:v "code.id" ] ;
       fhir:path [ fhir:v "code.id" ] ;
       fhir:max [ fhir:v "0" ]
     ] [
       fhir:id [ fhir:v "code.extension" ] ;
       fhir:path [ fhir:v "code.extension" ] ;
       fhir:max [ fhir:v "0" ]
     ] )
  ] . # 

# -------------------------------------------------------------------------------------

