Templates                        latest update: 2008-03-01

                              

What is a template?

First you are advised to click here to see a Template Specification.

A Longhand Template is a collector of ISO 15926-2 entity data types that together capture the representation of the information one wants to exchange.

It would be OK to use the longhand templates, but it would be a waste of server space and CPU cycles to store something over and over again that doesn't change. We can have, say, 65,000 instances of this template, and as a consequence would have to store hundreds of thousands rather useless objects. This is where the Shorthand Templates come into the play.

Shorthand Template (ST) is an n-ary relationship that only points at the variant "leaves" of the graph of its companion ("isDefinedBy") Longhand Template. These leaves are called "external references". We define the (RDF) Properties of a Shorthand Template like "possessor", "propertyType", etc. such that they can be understood by non-modellers.

NOTE - Please also refer to a W3C paper, where N-ary relations in OWL are being discussed.

Shorthand Templates require far less storage space and CPU cycles. In case there is doubt about their semantical content, the counterpart Longhand Template can be found via the isDefinedBy Property. The (generic) templates are defined in normative Template Specifications.

Normally only shorthand templates will be instantiated, but if so required the LTs can be instantiated as well. This is required when one wants to generate a Part 21 (ISO 10303-21) file.

Why Longhand Templates?

So why then do we have Longhand Templates? The LTs provide the full definition of the ST in terms of an application model that complies with the data model of ISO 15926-2. This warrants true lifecycle integration, because that was, and still is, the aim of that data model.

Template meta data

Longhand and Shorthand Templates are specializations of the entity data types multidimensional_object and class_of_information_representation.

Both are a subtype of thing. Thing has, next to its (system) identifier, five optional attributes that represent meta data about the record (not the information content!). These are (in OWL "camelBack" notation):

  • recordCopyCreated (the dateTime that this record copy was created)

  • recordCreated (the dateTime that the record of the original information was created)

  • recordCreator (the ID of the person or organization or system that created the original record)

  • logicallyDeleted (the dateTime that the record was declared logically deleted. Logical deletion means that whilst the record is still available in the system as a matter of historical record, it is no longer considered a valid statement and it is considered that it was never true.)

  • whyDeleted (reason for logical deletion)

The latter two are implemented by means of templates, because after the creation of a record it is not allowed to change it afterwards, and nobody creates a record that is logically deleted at creation time.

Root Template

The meta data of thing are extended for templates with three properties:

  • hasAccessCode - A mandatory property that tells something about the security sensitivity of the information represented by a template instance. It is used as a parameter in the ACL (Access Control List);
  • hasMetaInfo - A ClassOfInformationRepresentation that defines the applicable meta data about the information content of the template;
  • hasRule - A ClassOfInformationRepresentation that defines any rules, methods, or scripts that are applicable in any application software.

Specialization of template classes

Any template class can be specialized by constraining or fixing one or more of their Properties. In an OWL schema the constraining is done by entering a subclass behind 'allValuesFrom', and the "fixing" is done by entering the one-and-only permissible ID behind "hasValue".

For example, above template class ST-3401 could be specialized to say:

  • it is for the VESSEL class. This can be done by specializing the value of the 'possessor' from "PossibleIndividual" to the ID of the VESSEL class
  • not any propertyType, but a particular propertyType. This can be done by 'fixing' the ID of the applicable ClassOfIndirectProperty (here: 'DESIGN PRESSURE')   

This was the case with the specialized template class ST-VESSEL-3401-003 (below), that is stored in the normative ontology for Object Information Models (OIM).

A further specialization could be by a user organization by fixing the unitOfMeasure, where we could fix the ID of the Scale, e.g. the ID for "BAR GAUGE".

When data in any system needs to be mapped to ISO 15926 the OIM offers this kind of specialized templates, where only the ID of the physical object, the ID of the numerical value, and the date-time of effectiveness have to be filled in. This makes mapping a reasonably simple and deterministic exercise.

Below is the OWL listing for the specialized template ST-VESSEL-3401-003 that is part of the OIM for VESSELs. Note that we only show the Restrictions ("anonymous classes") for the properties that need further constraining. The rest is inherited from ST-3401. Also note that the cardinality is not repeated, because it is inherited as well.

    <part2:ClassOfMultidimensionalObject rdf:ID="ST-VESSEL-3401-003">

        <rdfs:subClassOf rdf:resource="http://tpl.rdlfacade.org/data#ST-3401"/>

        <rdfs:subClassOf>

            <owl:Restriction>

                <owl:onProperty rdf:resource="#possessor"/>

                <owl:allValuesFrom rdf:resource="http://rdl.rdlfacade.org/data#R349094"/> <!--the VESSEL class-->

            </owl:Restriction>

        </rdfs:subClassOf>

        <rdfs:subClassOf>

            <owl:Restriction>

                <owl:onProperty rdf:resource="#propertyType"/>

                <owl:hasValue rdf:resource="http://rdl.rdlfacade.org/data#R658433"/> <!--DESIGN PRESSURE-->

              </owl:Restriction>

        </rdfs:subClassOf>

        <rdfs:subClassOf>

            <owl:Restriction>

                <owl:onProperty rdf:resource="#basePropertyType"/>

                <owl:hasValue rdf:resource="http://rdl.rdlfacade.org/data#R354194"/> <!--PRESSURE-->

            </owl:Restriction>

        </rdfs:subClassOf>

   </part2:ClassOfMultidimensionalObject>

In case the PQR Ltd wants to warrant that always bar gauge is used as unit of measure, then they can further specialize this template to:

    <part2:ClassOfMultidimensionalObject rdf:ID="ST-VESSEL-3401-003">

        <rdfs:subClassOf rdf:resource="http://oim.rdlfacade.org/data#ST-VESSEL-3401-003"/>

        <rdfs:subClassOf>

            <owl:Restriction>

                <owl:onProperty rdf:resource="#unitOfMeasure"/>

                <owl:hasValue rdf:resource="http://rdl.rdlfacade.org/data#RDS994438"/> <!--BAR GAUGE-->

            </owl:Restriction>

        </rdfs:subClassOf>

   </part2:ClassOfMultidimensionalObject>

The ID of this specialized template may be the same or something totally different. It is different anyway, because it is preceded by a different URI. This is stored in the Façade of the PQR Ltd with a URI such as http://www.pqr-ltd.com/15926

RDF listing for template instance

Below is the representation of information about an instance (vessel V-6060), using instances of template classes. This is in RDF/XML format, as is used for moving data from the originating system to its System Façade, or for data hand-over from one Façade to another.

<rdf:RDF

    xml:base="http://www.pqr-ltd.com/p4502"

    xmlns="http://www.pqr-ltd.com/p4502#"

    xmlns:owl="http://www.w3.org/2002/07/owl#"

    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

    xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"

    xmlns:xsd="http://www.w3.org/2001/XMLSchema#"

    xmlns:part2="http://dm.rdlfacade.org/data#"

    xmlns:part4="http://rdl.rdlfacade.org/data#"

    xmlns:part7="http://tpl.rdlfacade.org/data#"

    xmlns:oim="http://oim.rdlfacade.org/data#">

 

    <owl:Ontology rdf:about="">

        <owl:imports rdf:resource="http://dm.rdlfacade.org/data#"/>

        <owl:imports rdf:resource="http://rdl.rdlfacade.org/data#"/>

        <owl:imports rdf:resource="http://tpl.rdlfacade.org/data#"/>

        <owl:imports rdf:resource="http://oim.rdlfacade.org/data#"/>

        <owl:imports rdf:resource="http://www.pqr-ltd.com/15926"/>

    </owl:Ontology>

 

<!--about vessel V-6060-->

 

    <part2:MultidimensionalObject rdf:ID="ST-267634">

        <rdf:type rdf:resource="http://oim.rdlfacade.org/data#ST-VESSEL-3401-002"/>

        <rdfs:label xml:lang="en">vessel V-6060 has a nominal volume capacity of 50 m3</rdfs:label>

        <part7:temporalWhole rdf:resource="http://www.pqr-ltd.com/p4502/cons#FPO-pcs347621"/>

        <part7:possessor rdf:resource="#FPO-ves347621-20060306T1357Z"/>

        <part7:context rdf:resource="http://www.pqr-ltd.com/p4502/cons#COTWP-438834"/> <!--Project 4502 CR23-->

        <part7:beginning rdf:resource="#XSDT_20060306T1357Z"/>

        <part7:propertyType rdf:resource="http://rdl.rdlfacade.org/data#RDS658578"/>

        <part7:numericalValue rdf:resource="#XSFL_50"/>

        <part7:unitOfMeasure rdf:resource="http://rdl.rdlfacade.org/data#RDS994572"/> <!--CUBIC METER-->

    </part2:MultidimensionalObject>

 

<!--Literals-->

 

    <part2:ClassOfInformationRepresentation rdf:ID="XSDT_20060306T1357Z">

        <rdf:type rdf:resource="http://rdl.rdlfacade.org/data#XmlSchemaDateTime"/>

        <part2:content rdf:datatype="http://www.w3.org/2001/XMLSchema#dateTime">2006-03-06T13:57:00Z</part2:content>

    </part2:ClassOfInformationRepresentation>

 

    <part2:ClassOfInformationRepresentation rdf:ID="XSFL_50">

        <rdf:type rdf:resource="http://rdl.rdlfacade.org/data#XmlSchemaFloat"/>

        <part2:content rdf:datatype="http://www.w3.org/2001/XMLSchema#float">50</part2:content>

    </part2:ClassOfInformationRepresentation>

 

</rdf:RDF>

Triples for template instances

For storage in a Façade the above file in RDF/XML format is automatically converted to the N3 triple format with Subject-Predicate-Object:

Subject Predicate Object
http://www.pqr-ltd.com/p4502 http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://www.w3.org/2002/07/owl#Ontology
http://www.pqr-ltd.com/p4502 http://www.w3.org/2002/07/owl#imports http://dm.rdlfacade.org/data#
http://www.pqr-ltd.com/p4502 http://www.w3.org/2002/07/owl#imports http://rdl.rdlfacade.org/data#
http://www.pqr-ltd.com/p4502 http://www.w3.org/2002/07/owl#imports http://tpl.rdlfacade.org/data#
http://www.pqr-ltd.com/p4502 http://www.w3.org/2002/07/owl#imports http://oim.rdlfacade.org/data#
http://www.pqr-ltd.com/p4502 http://www.w3.org/2002/07/owl#imports http://www.pqr-ltd.com/15926
http://www.pqr-ltd.com/p4502#ST-267634 http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://dm.rdlfacade.org/data#MultidimensionalObject
http://www.pqr-ltd.com/p4502#ST-267634 http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://oim.rdlfacade.org/data#ST-VESSEL-3401-002
http://www.pqr-ltd.com/p4502#ST-267634 http://www.w3.org/2000/01/rdf-schema#label "vessel V-6060 has a nominal volume capacity, based on volume, of 50 m3"@en
http://www.pqr-ltd.com/p4502#ST-267634 http://tpl.rdlfacade.org/data#temporalWhole http://www.pqr-ltd.com/p4502/cons#FPO-347621
http://www.pqr-ltd.com/p4502#ST-267634 http://tpl.rdlfacade.org/data#context http://www.pqr-ltd.com/p4502/cons#COTWP-438834
http://www.pqr-ltd.com/p4502#ST-267634 http://tpl.rdlfacade.org/data#beginning http://www.pqr-ltd.com/p4502#XSDT_20060306T1357Z
http://www.pqr-ltd.com/p4502#ST-267634 http://tpl.rdlfacade.org/data#possessor http://www.pqr-ltd.com/p4502#FPO-347621-20060306T1357Z
http://www.pqr-ltd.com/p4502#ST-267634 http://tpl.rdlfacade.org/data#propertyType http://rdl.rdlfacade.org/data#R658578
http://www.pqr-ltd.com/p4502#ST-267634 http://tpl.rdlfacade.org/data#basePropertyType http://rdl.rdlfacade.org/data#R356444
http://www.pqr-ltd.com/p4502#ST-267634 http://tpl.rdlfacade.org/data#numericalValue http://www.pqr-ltd.com/p4502#XSFL_50
http://www.pqr-ltd.com/p4502#ST-267634 http://tpl.rdlfacade.org/data#unitOfMeasure http://rdl.rdlfacade.org/data#R994572
http://www.pqr-ltd.com/p4502#XSDT_20060306T1357Z http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://dm.rdlfacade.org/data#ClassOfInformationRepresentation
http://www.pqr-ltd.com/p4502#XSDT_20060306T1357Z http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://dm.rdlfacade.org/data#XmlSchemaDateTime
http://www.pqr-ltd.com/p4502#XSDT_20060306T1357Z http://dm.rdlfacade.org/data#content "2006-03-06T13:57:00Z"^^http://www.w3.org/2001/XMLSchema#dateTime
http://www.pqr-ltd.com/p4502#XSFL_50 http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://dm.rdlfacade.org/data#ClassOfInformationRepresentation
http://www.pqr-ltd.com/p4502#XSFL_50 http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://dm.rdlfacade.org/data#XmlSchemaFloat
http://www.pqr-ltd.com/p4502#XSFL_50 http://dm.rdlfacade.org/data#content "50"^^http://www.w3.org/2001/XMLSchema#float

Ontology for Templates

RDF/XML listings of shorthand templates are collected in the normative Ontology for Templates. Because for quite some time to come there will be the need for addition of templates to that ontology, that ontology cannot be on paper because the revision cycle time of ISO standards is too long. For that reason it must be on the Internet. The advantage of it being on the Internet is also that it can be imported in other ontologies.

For the instantiation of longhand templates a FOL (first-order logic) specification for each template class has been defined (for the "initial set", that is). See http://www.rdlfacade.org/files/iso15926-7/ts/3401_rules.pdf for the rules of template 3401.

Ultimately we expect some 200 generic templates.