6.2 Special Conventions for Template Tables
Prev | 6 Form of Template Specifications | Next

## 6.2 Special Conventions for Template Tables

### 6.2.1 Multiple Value Sets Depending On Different Conditions

When a Content Item may have different value sets, each depending on different conditions, the description of each different case begins in a separate row of the Template Table.

### 6.2.2 Target Content Items of Relationships

When it is necessary to specify the Target Content Item(s) of a relationship, they are specified in the row(s) immediately following the Source Content Item. The Nesting level of a Target Content Item (or set of Target Content Items specified indirectly via an 'include Template' macro) is one greater than the Nesting Level of the corresponding Source Content Item, as indicated by an increase in the number of ">" characters in the nesting level.

When a Content Item may be the Source of multiple relationships having different Relationship Types and/or different Relationship Modes and/or different patterns of Target Content Item(s), the description of each different case begins in a separate row of the Template Table.

When the Source Content Item of a relationship has VM of greater than 1, the specified pattern of Target Content Items applies to all instantiations of the Source Content Item.

### Note

For example, if a Template specifies that the VM of a Source Content Item is 1-n and specifies a By-value relationship to two CODE Content Items with particular value set constraints, then each instantiation of the Source Content Item has a By-value relationship to two CODE Content Items with the specified value constraints.

When a Source Content Item that has a Requirement Type of U, UC or MC is not present (is not instantiated), no Target Content Items of that Source Content Item are present, even if one or more of the Target Content Items is designated with a Requirement Type of M or MC.

### Note

In other words, potential children are not present when there is no parent.

### 6.2.3 Inclusion of Templates

A Template may specify another Template to be included by specifying "INCLUDE" in the Value Type field and the identifier of the included Template in the Concept Name field. All of the rows of the specified Template are in included in the invoking Template, effectively substituting the specified template for the row where the inclusion is invoked. Whether or not the inclusion is user optional, mandatory or conditional is specified in the Requirement and Condition fields. The number of times the included Template may be repeated is specified in the VM field.

#### 6.2.3.1 Template Parameters

A Template that is included by another Template may include parameters that are replaced by values defined in the invoking Template. Parameters may be used to specify coded concepts or Context Groups in the Concept Name, Condition, or Value Set Constraint fields of a Template.

An included Template that accepts parameters shall be introduced by a table listing those parameters of the form:

Parameter Name | Parameter Usage
--- | ---
... | ...
... | ...

Parameters are indicated by a name beginning with the character "$".

The invoking Template may specify the value of the parameters in the included Template by name in the Value Set Constraint field of the INCLUDE row. The parameter in the included Template shall be replaced by the specified parameter value. Specification of a parameter value shall be of one of the following forms:

Notation | Definition
--- | ---
$parametername = EV or DT (CV, CSD, "CM") | The parameter passed to the template is the specified coded term.
$parametername = (CV, CSD, "CM") | The parameter passed to the template is the specified coded term, used as a parameter in a Condition field of the included Template.
$parametername = BCID or DCID (CID) CNAME | The parameter passed to the template is the Context Group.
$parametername = MemberOf {BCID or DCID (CID) CNAME} | The parameter passed to the template is a single coded term from the Context Group in curly braces.

The specification of a parameter value is valid only for the directly included template. Therefore, it needs to be explicitly respecified in templates intermediate between the originally specifying Template and the target Template. The intermediate Template may use the same parameter name as used by the Template it invokes; in such a case, the intermediate Template would invoke the subsidiary Template with a specification in the Value Set Constraint field such as:

$parametername = $parametername

### Note

In this case, the left hand instance of $parametername is the name in the subsidiary template, and the right hand instance is the (parametrized) value passed into the current template.

The invoking template is not required to specify all parameters of included templates. If not specified, the value set (term or context group) for that parameter is unconstrained. An unconstrained value in a Condition will cause the condition to fail.

### 6.2.4 Post-coordinated Codes and Has Concept Modifier Relationship

Though it may not be explicitly shown in a particular Template, the use of any coded Concept Name in any Content Item may be defined in a post-coordinated rather than pre-coordinated manner, unless explicitly forbidden by the IOD or the Template.

Accordingly, any such Content Item may have any number of Target Content Items via a "HAS CONCEPT MOD" relationship, even if not explicitly specified in a Template. Each Target Content Item of such a relationship may be more complicated than a single Content Item if the IOD permits (i.e., the post-coordinated concept may potentially be defined by a complex sub-tree).

### 6.2.5 Extension of Templates

An Extensible Template may be extended in an Application generating SOP Instances to include additional Content Items in its definition. Such Content Items shall not duplicate concepts for which an encoding is defined in the Template. I.e., if a method is provided for the encoding of a concept in the Template, that concept shall not be encoded using a different Content Item in an extension to the Template.

### Note

There is no requirement that the included additional Content Items in a Template extension be placed at the end of the Template. The additional Content Items may be included at any semantically appropriate location in the Template, regardless of whether the order of Content Items in the Template is significant.

A Non-extensible Template shall not be modified in an Application by the addition of Content Items to its definition.

### Note

The set of Content Items in either an Extensible or a Non-extensible Template may be changed in subsequent editions of the Standard, in accordance with the procedures of the DICOM Standards Committee.

A Non-Extensible Template may include a Template that is Extensible. In invoking such a Template, the content structure of SOP Instances created from the Non-Extensible Template may vary according to the varying content structure allowed by the extension of the included Template.

### Note

Specification of such extensible content in a Non-Extensible Template may be desirable if the Template defines, e.g., a fixed top level structure into which a variety of lower level structures may be "plugged".

Prev | Up | Next
6 Form of Template Specifications | Home | 7 DCMR Context Group Specifications