Implementation of the meta data model
In the following, we develop a proposal how semantically structured documents could be created with the help of commercial Office products. We proceed on the assumption that the Office products will provide a function for the creation of templates, allowing the user by means of a toolbox e.g. to place semantically defined control and text elements (based on given XML-schemata) on a template to be designed.

OpenOffice.org



Microsoft Office 2003

With the help of such a function, a template like the following could be created.





We have chosen the example of an invoice derived from the business letter accordingly to the 1dok meta data model. In addition to the contents of the business letter, it will have contents as

invoice number
a list of invoice positions with several specifications like
position number,
service/item charged,
price,
a net total,
the VAT amount,
an invoice amount, etc.

Below you see the corresponding XML-schema. It reveals that the invoice is derived from the business letter and which are the contents exceeding those of the business letter.

(Schema for the business letter you can find here:
http://www.1dok.org/schemas/XML/eng/BusinessLetter.xsd.
Schema for the invoice you can find here:
http://www.1dok.org/schemas/XML/eng/Invoice.xsd.)


<?xml version="1.0" encoding="UTF-8"?>
<!--edited with XMLSPY v5 rel. 2 (http://www.xmlspy.com) by Ursula Bartels, MSK GESELLSCHAFT FUER AUTOMATISIERUNG MBH, 2003-03-04-->

<schema
targetNamespace="http://www.1dok.org/schemas#"
xmlns="http://www.w3.org/2001/XMLSchema"
xmlns:ed="http://www.1dok.org/schemas#"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:dcterms="http://purl.org/dc/terms/"
xmlns:vCard="http://www.w3.org/2001/vcard-rdf/3.0#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
elementFormDefault="qualified"
attributeFormDefault="qualified">

<include schemaLocation= "http://www.1dok.org/schemas/XML/eng/BusinessLetter.xsd"/>

<complexType name="Invoice" mixed="true">
<complexContent mixed="true">
<extension base="ed:BusinessLetterDescription">
<sequence>
<element name="invoiceNo" type="rdf:PropertyType"/>
<element name="invoiceItem" type="rdf:PropertyType" maxOccurs="unbounded"/>
<element name="extraCharges" type="rdf:PropertyType"/>
<element name="totalAmount" type="rdf:PropertyType"/>
<element name="valueAddedTaxRate" type="rdf:PropertyType"/>
<element name="invoiceTotal" type="rdf:PropertyType"/>
<element name="termsOfPayment" type="rdf:PropertyType"/>
</sequence>
</extension>
</complexContent>
</complexType>
<complexType name="InvoiceItemRefinement">
<complexContent>
<extension base="rdf:DescriptionType">
<sequence>
<element name="itemNo" type="rdf:PropertyType"/>
<element name="descriptionOfService" type="rdf:PropertyType"/>
<element name="price" type="rdf:PropertyType"/>
</sequence>
</extension>
</complexContent>
</complexType>
</schema>


On the basis of such a template, semantically structured documents can be originated.

With OpenOffice as an example, this may happen in a known way by choosing the function
File->New->Out Template
and in the case of MS-Office 2003 by choosing the function
File->New and a corresponding template in the range of duty.

The graph below shows an invoice that has been originated as an instance as it were of the template created above.





Proposal for Implementation you can find here:
OpenOffice.org
Microsoft Office 2003
top
copyright 1dok.org 2002 | home |