SNOMED Documentation Search


Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This section provides a brief description of each rule listed above in the normative specification.

templateSlot =

 templateReplaceSlot

 templateReplacementSlot /

templateRemoveSlot

templateInformationSlot

 

A templateSlot is part of a template that is either replaced with a value (i.e. a templateRelacementSlot), or removed after the information it contains is interpreted (i.e. a templateInformationSlot).

templateReplacementSlot = conceptReplacementSlot / expressionReplacementSlot / tokenReplacementSlot / concreteValueReplacementSlot
  A templateReplacementSlot is a placeholder whose value can be completed at a subsequent time. A templateReplacementSlot may be either a conceptReplacementSlot, an expressionReplacementSlot, a tokenReplacementSlot or a concreteValueReplacementSlot.
templateReplaceSlot
conceptReplacementSlot = "[["
ws
ws "+" ws "id" ws [
replaceInfo
"(" ws expressionConstraint ws ")" ws] [
slotInfo
slotName ws] "]]"
 
 templateRemoveSlot = "[[" ws [slotInfo
 A conceptReplacementSlot starts and ends with double square brackets (i.e. "[[ ... ]]"). The first non-whitespace character inside the brackets must always be a plus sign (i.e. "+"), followed by the text "id". A conceptReplacementSlot may then optionally include an expressionConstraint (in round brackets) to restrict the valid values that may replace the slot, followed by an option slotName.
expressionReplacementSlot = "[[" ws "+" ws ["scg" ws] [ "(" ws expressionConstraint ws ")" ws] [slotName ws] "]]"
 
 replaceInfo = conceptReplaceInfo / expressionReplaceInfo / constraintReplaceInfo / stringReplaceInfo  conceptReplaceInfo = "id" [ ws "(" ws expressionConstraint ws ")" ]  expressionReplaceInfo = "scg" [ ws "(" ws expressionConstraint ws ")" ]  constraintReplaceInfo = "ecl" [ ws "(" ws expressionConstraintTemplate ws ")" ]  stringReplaceInfo = "str" [ ws "(" ws slotStringSet ws ")" ]  slotStringSet = slotString *(ws "," ws slotString)  slotInfo = [slotCardinality ws] [slotName ws] [slotReference ws]  slotCardinality  = nonNegativeInteger ".." (nonNegativeInteger / "*")  slotName = "@" slotString  slotReference = "$" slotString  slotString = *nonQuoteString / (doubleQM *nondoubleQuoteString doubleQM) /  (singleQM *nonsingleQuoteString singleQM)  nonQuoteString = %x21 / %x23 / %x25
 An expressionReplacementSlot starts and ends with double square brackets (i.e. "[[..]]"). The first non-whitespace character inside the brackets must always be a plus sign (i.e. "+"), followed optionally by the text "scg". Note that "scg" is the default replacement slot type. An expressionReplacementSlot may then optionally include an expressionConstraint (in round brackets) to restrict the valid values that may replace the slot, followed by an option slotName.
tokenReplacementSlot = "[[" ws "+" ws "tok" ws [ "(" ws slotTokenSet ws ")" ws] [slotName ws] "]]"

A tokenReplacementSlot starts and ends with double square brackets (i.e. "[[..]]"). The first non-whitespace character inside the brackets must always be a plus sign (i.e. "+"), followed by the text "tok". A tokenReplacementSlot may then optionally include a slotTokenSet (in round brackets) to restrict the valid values that may replace the slot, followed by an option slotName.
concreteValueReplacementSlot = stringReplacementSlot / integerReplacementSlot / decimalReplacementSlot

A concreteValueReplacementSlot may either be a stringReplacementSlot, an integerReplacementSlot, or a decimalReplacementSlot.
stringReplacementSlot = "[[" ws "+" ws "str" ws [ "(" ws slotStringSet ws ")" ws] [slotName ws] "]]"
 A stringReplacementSlot starts and ends with double square brackets (i.e. "[[..]]"). The first non-whitespace character inside the brackets must always be a plus sign (i.e. "+"), followed by the text "str". A stringReplacementSlot may then optionally include a slotStringSet (in round brackets) to restrict the valid values that may replace the slot, followed by an option slotName.
integerReplacementSlot = "[[" ws "+" ws "int" ws [ "(" ws slotIntegerSet ws ")" ws] [slotName ws] "]]"

An integerReplacementSlot starts and ends with double square brackets (i.e. "[[..]]"). The first non-whitespace character inside the brackets must always be a plus sign (i.e. "+"), followed by the text "int". An integerReplacementSlot may then optionally include a slotIntegerSet (in round brackets) to restrict the valid values that may replace the slot, followed by an option slotName.
decimalReplacementSlot = "[[" ws "+" ws "dec" ws [ "(" ws slotDecimalSet ws ")" ws] [slotName ws] "]]"

A decimalReplacementSlot starts and ends with double square brackets (i.e. "[[..]]"). The first non-whitespace character inside the brackets must always be a plus sign (i.e. "+"), followed by the text "dec". A decimalReplacementSlot may then optionally include a slotDecimalSet (in round brackets) to restrict the valid values that may replace the slot, followed by an option slotName.
slotTokenSet = slotToken *(mws slotToken)

A slotTokenSet consists of one or more slotTokens separated by mandatory white space (i.e. mws).
slotStringSet = slotString *(mws slotString)
  a slotStringSet consists of one or more slotStrings separated by mandatory white space (i.e. mws).
slotIntegerSet = ( "#" integerValue / slotIntegerRange) *(mws ("#" integerValue / slotIntegerRange))
  A slotIntegerSet consists of one or more slotIntegers separated by mandatory white space (i.e. mws).
slotDecimalSet = ( "#" decimalValue / slotDecimalRange) *(mws ("#" decimalValue / slotDecimalRange))

A slotDecimalSet consists of one or more slotDecimals separated by mandatory white space (i.e. mws).
slotIntegerRange = ( slotIntegerMinimum to [ slotIntegerMaximum ] ) / ( to slotIntegerMaximum )

A slotIntegerRange includes either a slotIntegerMinimum, a slotIntegerMaximum, or both. The slotIntegerMinimum and slotIntegerMaximum are separated by a 'to' token.
slotIntegerMinimum = [ exclusiveMinimum ] "#" integerValue

A slotIntegerMinimum includes a minimum integerValue preceded by a "#". By default the minimum is inclusive (i.e. the minimum value is a valid value in the range). However, the minimum value may be declared to be exclusive (i.e. not a valid value in the range) by preceding it with the exclusiveMinimum symbol (i.e. ">").
slotIntegerMaximum = [ exclusiveMaximum ] "#" integerValue

A slotIntegerMaximum includes a maximum integerValue preceded by a "#". By default the maximum is inclusive (i.e. the maximum value is a valid value in the range). However, the maximum value may be declared to be exclusive (i.e. not a valid value in the range) by preceding it with the exclusiveMaximum symbol (i.e. "<").
slotDecimalRange = ( slotDecimalMinimum to [ slotDecimalMaximum ] ) / ( to slotDecimalMaximum )

A slotDecimalRange includes either a slotDecimalMinimum, a slotDecimalMaximum, or both. The slotDecimalMinimum and slotDecimalMaximum are separated by a 'to' token.
slotDecimalMinimum = [ exclusiveMinimum ] "#" DecimalValue

A slotDecimalMinimum includes a minimum decimalValue preceded by a "#". By default the minimum is inclusive (i.e. the minimum value is a valid value in the range). However, the minimum value may be declared to be exclusive (i.e. not a valid value in the range) by preceding it with the exclusiveMinimum symbol (i.e. ">").
slotDecimalMaximum = [ exclusiveMaximum ] "#" DecimalValue

A slotDecimalMaximum includes a maximum decimalValue preceded by a "#". By default the maximum is inclusive (i.e. the maximum value is a valid value in the range). However, the maximum value may be declared to be exclusive (i.e. not a valid value in the range) by preceding it with the exclusiveMaximum symbol (i.e. "<").
exclusiveMinimum = ">"

The exclusiveMinimum symbol is ">". When used before the minimum value, it declares that this value is not a valid part of the range.
exclusiveMaximum = "<"

The exclusiveMaximum symbol is "<". When used before the maximum value, it declares that this value is not a valid part of the range.
slotName = "@" (nonQuoteStringValue / slotString)

A slotName starts with an at symbol (i.e. "@"), followed by either a quoted or unquoted string.
slotToken = definitionStatus / memberOf / constraintOperator / conjunction / disjunction / exclusion / reverseFlag / expressionComparisonOperator / numericComparisonOperator / stringComparisonOperator

A slotToken is any token from SNOMED CT Compositional Grammar or the SNOMED CT Expression Constraint Language. This includes the definitionStatus, memberOf, constraintOperator, conjunction, disjunction, exclusion, reverseFlag, expressionComparisonOperator, numericComparisonOperator and stringComparisonOperator tokens.
slotString = QM stringValue QM

A slotString is a string value enclosed in quotation marks.
nonQuoteStringValue = *(%x21 / %x23-26 / %x28-3F / %x41-5A / %x5C / %x5E-7E)   ; string with no ws, quotes, at
,
or
dollar
square brackets

A nonQuoteStringValue includes any character that is not whitespace, quotes, or the @ symbol.
templateInformationSlot = "[[" ws slotInformation ws "]]"

A templateInformationSlot starts and ends with double square brackets (i.e. "[[ ... ]]"), and contains slotInformation.
slotInformation = [cardinality ws] [slotName ws]

A slotInformation consists of either a cardinality, a slotName or both.
  nondoubleQuoteString = %x21 / %x23 / %x25-3F / %x41-7E   ; no ws, double quotes, at or dollar  nonsingleQuoteString = %x21-23 / %x25-26 / %x28-3F / %x41-7E    ; no ws, single quotes, at or dollar  nonNegativeInteger =  (%x31-39 *(%x30-39) ) / %x30    ; (digitNonZero *digit) / zero  doubleQM = %x22   ; Double quotation mark  singleQM = %x27   ; Single quotation mark