Greetings all, I reviewed the current V3 Data Type draft [v3dt] to see what issues might arise during the creation of an XML-based Implementable Technology Specification (ITS), and I'd like to report on what I found. We may ultimately represent V3 data types using DTDs, Schemas [Schema1] [Schema2], Xlink [XLink], some variant of Gunther Schadow's draft XML ITS for V3 data types [v3dt_xml], etc. The issues listed below seem to be relevant regardless of the specific XML style used. Any XML style used will need to specifically address the following issues and state how they are represented. (The page numbers below refer to the PDF version of the V3 Data Type draft, available at [v3dt].) 1 Generalized types 2 Generic types 3 Data type conversions 4 ITS vs. application-layer characters 5 Data type extensions 6 "Looseness" of the XML representation 7 Specific data type issues ----------------------------- ----------------------------- 1 Generalized types ----------------------------- ----------------------------- 1.2.3 Generalized types (pg 11): Data types maintain an inheritance relationship with each other. For instance, data type "Integer" is a specialization of data type "Quantity". Data type "Ratio" is defined as a ratio of any two quantities, and therefore can be a ratio of any two data types subsumed by data type "Quantity". ----------------------------- ----------------------------- 2 Generic types ----------------------------- ----------------------------- 1.2.4 Generic Types (pg 12): Generic data types are incomplete data type definitions. Before you can instantiate a generic type, you must complete its definition. For instance, the data type "Interval" has an attribute "low" and an attribute "high". These attributes are defined as type "OrderedType", where ordered types can be instantiated as data type "Integer" or "Float" or "PhysicalQuantity", etc. ----------------------------- ----------------------------- 3 Data type conversions ----------------------------- ----------------------------- 1.2.7 Implicit Type Conversion (pg 22): The HMD for a message may say to send a particular RIM attribute using data type X. A data type conversion matrix states that data types Y or Z can be sent instead of data type X, and states how to convert the alternate data types Y or Z into the one that was required, X. As a result, a message sender can send the message using data type X, Y, or Z. For instance, if a message requires a FreeText data type, a String data type can be sent instead, and can be converted into a FreeText data type. ----------------------------- ----------------------------- 4 ITS vs. application-layer characters ----------------------------- ----------------------------- 2.2.3 ITS Responsibilities (pg 42): Characters with special meaning to the ITS (such as "<", "&") may occur in a number of data types (such as String, etc). ----------------------------- ----------------------------- 5 Data type extensions ----------------------------- ----------------------------- o Some data types are possible extensions of (almost) any other data type. Examples include: o 1.2.11 Incomplete Information (pg 31): The NoInformation data type can be sent instead of any other value in almost every field in a message. o 5.2 General Annotations (pg 152): "Note that this annotated information data type, as a Message Element Type (MET) could be used to annotate any Message Element Instance (MEI)...". ----------------------------- ----------------------------- 6 "Looseness" of the XML representation ----------------------------- ----------------------------- o There will be cases where an XML DTD (or Schema) cannot explicitly represent HL7 business rules. ("Explicitly represent" in this case means modeling the constraint in a DTD or Schema such that an XML processor can validate the constraint.) The "looser" a particular XML representation, the less HL7 business rules explicitly represented. There are several data types where the "looseness" of the XML representation can be varied. For example: o 3.3.3 Person Name (pg 94): Attribute "classifiers" of PersonNamePart is of type "SET OF Code Value". The vocabulary domain for these code values are broken up into three axes. For a particular PersonNamePart, only one value from axis 1 is allowed while more then one value from axis 2 and axis 3 are allowed. o 5.4.3 Parametric Probability Distribution (pg 161): The value of attribute "type" determines what additional attributes are part of the instantiated data type. ----------------------------- ----------------------------- 7 Specific data type issues ----------------------------- ----------------------------- o 2.3 Free Text (pg 47) o 2.3.2 Binary Data (pg 55) : The encoding of bytes is an ITS layer issue. o 3.5.1 Concept Descriptor (pg 122) o 3.5.2 Code Translation (pg 123): What exactly does the attribute "origin" make reference to? In [v3dt_xml], Gunther models "origin" as an IDREF and points to an ID value, but there is no attribute defined in [v3dt] from which the ID value was derived. o 4.2 Integer Number (pg 133): The representation of positive and negative infinity is up to the ITS. o 4.3 Floating Point Number (pg 134): Character string literal representation of floating point numbers is up to the ITS. (From [Schema2]: "The motivation for the number datatype was to allow the user to specify a value that could take any legal lexical representation for a numeric quantity. This turns out to be problematic, however, due to the large number of extant representations some of which cannot be distinguished without extra information. Having to define a lexical representation facet for number seems to defeat its purpose and, thus, the number datatype may be removed from this specification.") o 4.6.1 Point in Time (pg 144): HL7 may continue to use the format used in the v2.3 TS data type, rather then the ISO 8601 [ISO 8601] format likely to be adopted by schemas. (Therefore, there may be the need to perform date/time format translations when getting data into an XML ITS). o 5.4.3 Parametric Probability Distribution (pg 161): Attribute "standard deviation" is of type "dif(T)" - which is the difference of two values of type T. The data type of "dif(T)" may or may not be the same data type as "T", depending on the type. Thus, dif(T) of integers is an integer while dif(T) of PointInTime will be a PhysicalQuantity in the dimension of time. ----------------------------- ----------------------------- References ----------------------------- ----------------------------- [v3dt] HL7 v3.0 Data Types Specification, Version 0.9. March 22, 1999. http://aurora.rg.iupui.edu/v3dt/ [v3dt_xml] HL7 v3.0 Data Types: Implementable Technology Specification (ITS): Extensible Markup Language. http://aurora.rg.iupui.edu/v3dt/ITS-XML.html [Schema1] XML Schema Part 1: Structures. W3C Working Draft 6-May-1999 http://www.w3.org/1999/05/06-xmlschema-1/ [Schema2] XML Schema Part 2: Datatypes. World Wide Web Consortium Working Draft 06-May-1999. http://www.w3.org/1999/05/06-xmlschema-2/ [XLink] XML Linking Language (XLink). World Wide Web Consortium Working Draft 3-March-1998. http://www.w3.org/TR/1998/WD-xlink-19980303 [ISO 8601] Representations of dates and times. See http://www.iso.ch/markete/8601.pdf Available from http://www.w3.org/TR/1998/WD-xsl-19981216 Take care, Bob --------------------------------------------------------------------- To unsubscribe from this list, send a message to majordomo@ismi.net with "unsubscribe cq" (without the quotes) in the message body.