OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

ubl-dev message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: RE: [ubl-dev] Simpler-Than-UBL Design Rules


Hi David

What might persuade me completely would be a Standardisation
of the AJAX configuration xml files you mention. But then maybe
XForms could be seen as a first step in that :-)

Many thanks for these very informative points.

I still hope the matter stays open about what AJAX, XForms and the
like can cope with in a browser (or equivalent) environment, or, for
that matter, in an open office environment - as regards XML validation
capabilities. This is in view of the possibility that there is a strong 
need for artefacts with the UBL model but much simpler schemas.

Below is an example of what I'd think we'd be looking for (in this
case for the simplified price list as a subset of Catalogue, extendable
of course to cover more of Catalogue type as and when necessary):

They're a bit long, apologies. The advantage over just extending
and extending the home-brewed pricelist schema is that using the
'simpler than UBL' one allows us just to keep adding further simplified
UBL elements and types as necessary with a simple transformation
to and from UBL-proper which amounts to a simple algorithm rather
than mapping and that means no change to some of the software
such as the stylesheet(s) required for the transformation to and
from UBL.

Here's the instance 

<?xml version="1.0" encoding="UTF-8"?>
<Catalogue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:noNamespaceSchemaLocation="PreisShare-STUDR-UBL-CatalogueSubset-v0-2.xsd">
	<UBLVersionID schemeID="normalizedString">normalizedString</UBLVersionID>
	<CustomizationID schemeID="normalizedString">normalizedString</CustomizationID>
	<ProfileID schemeID="normalizedString">normalizedString</ProfileID>
	<ID schemeID="normalizedString">normalizedString</ID>
	<IssueDate>1967-08-13</IssueDate>
	<ProviderParty>
		<PartyIdentification>
			<ID schemeID="normalizedString">normalizedString</ID>
		</PartyIdentification>
		<PartyName>
			<Name>String</Name>
		</PartyName>
		<PostalAddress>
			<CityName>String</CityName>
			<PostalZone>String</PostalZone>
			<CountrySubentity>String</CountrySubentity>
			<AddressLine>
				<Line>String</Line>
			</AddressLine>
			<AddressLine>
				<Line>String</Line>
			</AddressLine>
			<Country>
				<IdentificationCode listID="normalizedString" listURI="http://docs.oasis-open.org/ubl/os-ubl-2.0/cl/gc/default/CountryIdentificationCode-2.0.gc";>normalizedString</IdentificationCode>
			</Country>
		</PostalAddress>
	</ProviderParty>
	<ReceiverParty>
		<PartyIdentification>
			<ID schemeID="normalizedString">normalizedString</ID>
		</PartyIdentification>
		<PartyName>
			<Name>String</Name>
		</PartyName>
		<PostalAddress>
			<CityName>String</CityName>
			<PostalZone>String</PostalZone>
			<CountrySubentity>String</CountrySubentity>
			<AddressLine>
				<Line>String</Line>
			</AddressLine>
			<AddressLine>
				<Line>String</Line>
			</AddressLine>
			<Country>
				<IdentificationCode listID="normalizedString" listURI="http://docs.oasis-open.org/ubl/os-ubl-2.0/cl/gc/default/CountryIdentificationCode-2.0.gc";>normalizedString</IdentificationCode>
			</Country>
		</PostalAddress>
	</ReceiverParty>
	<CatalogueLine>
		<ID schemeID="normalizedString">normalizedString</ID>
		<RequiredItemLocationQuantity>
			<Price>
				<PriceAmount currencyID="normalizedString">3.1415926535897932384626433832795</PriceAmount>
				<BaseQuantity unitCode="normalizedString">3.1415926535897932384626433832795</BaseQuantity>
			</Price>
		</RequiredItemLocationQuantity>
		<Item>
			<Name>String</Name>
			<SellersItemIdentification>
				<ID schemeID="normalizedString">normalizedString</ID>
			</SellersItemIdentification>
		</Item>
	</CatalogueLine>
	<CatalogueLine>
		<ID schemeID="normalizedString">normalizedString</ID>
		<RequiredItemLocationQuantity>
			<Price>
				<PriceAmount currencyID="normalizedString">3.1415926535897932384626433832795</PriceAmount>
				<BaseQuantity unitCode="normalizedString">3.1415926535897932384626433832795</BaseQuantity>
			</Price>
		</RequiredItemLocationQuantity>
		<Item>
			<Name>String</Name>
			<SellersItemIdentification>
				<ID schemeID="normalizedString">normalizedString</ID>
			</SellersItemIdentification>
		</Item>
	</CatalogueLine>
</Catalogue>



And here's the schema which ought, I hope, to be relatively technology friendly:




<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"; elementFormDefault="qualified">
	<xsd:complexType name="AddressType">
		<xsd:sequence>
			<xsd:element ref="CityName" minOccurs="0"/>
			<xsd:element ref="PostalZone" minOccurs="0"/>
			<xsd:element ref="CountrySubentity" minOccurs="0"/>
			<xsd:element ref="AddressLine" minOccurs="0" maxOccurs="unbounded"/>
			<xsd:element ref="Country" minOccurs="0"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="AddressLine" type="AddressLineType"/>
	<xsd:complexType name="AddressLineType">
		<xsd:sequence>
			<xsd:element ref="Line"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="BaseQuantity" type="SimpleQuantityType"/>
	<xsd:element name="Catalogue" type="CatalogueType"/>
	<xsd:complexType name="CatalogueType">
		<xsd:sequence>
			<xsd:element ref="UBLVersionID" minOccurs="0"/>
			<xsd:element ref="CustomizationID" minOccurs="0"/>
			<xsd:element ref="ProfileID" minOccurs="0"/>
			<xsd:element ref="ID"/>
			<xsd:element ref="IssueDate"/>
			<xsd:element ref="ProviderParty"/>
			<xsd:element ref="ReceiverParty"/>
			<xsd:element ref="CatalogueLine" maxOccurs="unbounded"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="CatalogueLine" type="CatalogueLineType"/>
	<xsd:complexType name="CatalogueLineType">
		<xsd:sequence>
			<xsd:element ref="ID"/>
			<xsd:element ref="RequiredItemLocationQuantity" minOccurs="0"/>
			<xsd:element ref="Item"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="CityName" type="SimpleTextType"/>
	<xsd:element name="Country" type="CountryType"/>
	<xsd:complexType name="CountryType">
		<xsd:sequence>
			<xsd:element ref="IdentificationCode" minOccurs="0"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="CountrySubentity" type="SimpleTextType"/>
	<xsd:element name="CustomizationID" type="SimpleIdentifierType"/>
	<xsd:element name="ID" type="SimpleIdentifierType"/>
	<xsd:element name="IdentificationCode" type="CountryIdentificationCodeType"/>
	<xsd:element name="IssueDate" type="DateType"/>
	<xsd:element name="Item" type="ItemType"/>
	<xsd:complexType name="ItemType">
		<xsd:sequence>
			<xsd:element ref="Name" minOccurs="0"/>
			<xsd:element ref="SellersItemIdentification" minOccurs="0"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:complexType name="ItemIdentificationType">
		<xsd:sequence>
			<xsd:element ref="ID"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:complexType name="ItemLocationQuantityType">
		<xsd:sequence>
			<xsd:element ref="Price" minOccurs="0"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="Line" type="SimpleTextType"/>
	<xsd:element name="Name" type="SimpleTextType"/>
	<xsd:complexType name="PartyType">
		<xsd:sequence>
			<xsd:element ref="PartyIdentification" minOccurs="0"/>
			<xsd:element ref="PartyName" minOccurs="0"/>
			<xsd:element ref="PostalAddress" minOccurs="0"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="PartyIdentification" type="PartyIdentificationType"/>
	<xsd:complexType name="PartyIdentificationType">
		<xsd:sequence>
			<xsd:element ref="ID"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="PartyName" type="PartyNameType"/>
	<xsd:complexType name="PartyNameType">
		<xsd:sequence>
			<xsd:element ref="Name"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="PostalAddress" type="AddressType"/>
	<xsd:element name="PostalZone" type="SimpleTextType"/>
	<xsd:element name="Price" type="PriceType"/>
	<xsd:complexType name="PriceType">
		<xsd:sequence>
			<xsd:element ref="PriceAmount"/>
			<xsd:element ref="BaseQuantity" minOccurs="0"/>
		</xsd:sequence>
	</xsd:complexType>
	<xsd:element name="PriceAmount" type="AmountType"/>
	<xsd:element name="ProfileID" type="SimpleIdentifierType"/>
	<xsd:element name="ProviderParty" type="PartyType"/>
	<xsd:element name="ReceiverParty" type="PartyType"/>
	<xsd:element name="RequiredItemLocationQuantity" type="ItemLocationQuantityType"/>
	<xsd:element name="SellersItemIdentification" type="ItemIdentificationType"/>
	<xsd:element name="UBLVersionID" type="SimpleIdentifierType"/>
	<xsd:complexType name="AmountType">
		<xsd:simpleContent>
			<xsd:extension base="xsd:decimal">
				<xsd:attribute name="currencyID" type="xsd:normalizedString" use="required"/>
			</xsd:extension>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:complexType name="CountryIdentificationCodeType">
		<xsd:simpleContent>
			<xsd:extension base="xsd:normalizedString">
				<xsd:attribute name="listID" type="xsd:normalizedString" use="optional" default="ISO3166-1"/>
				<xsd:attribute name="listURI" type="xsd:anyURI" use="optional" default="http://docs.oasis-open.org/ubl/os-ubl-2.0/cl/gc/default/CountryIdentificationCode-2.0.gc"/>
			</xsd:extension>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:simpleType name="DateType">
		<xsd:restriction base="xsd:date"/>
	</xsd:simpleType>
	<xsd:simpleType name="IndicatorType">
		<xsd:restriction base="xsd:boolean">
			<xsd:pattern value="false"/>
			<xsd:pattern value="true"/>
		</xsd:restriction>
	</xsd:simpleType>
	<xsd:complexType name="NameType">
		<xsd:simpleContent>
			<xsd:extension base="xsd:string">
				<xsd:attribute name="languageID" type="xsd:language" use="optional"/>
			</xsd:extension>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:simpleType name="NumericType">
		<xsd:restriction base="xsd:decimal"/>
	</xsd:simpleType>
	<xsd:simpleType name="PercentType">
		<xsd:restriction base="xsd:decimal"/>
	</xsd:simpleType>
	<xsd:complexType name="SimpleCodeType">
		<xsd:simpleContent>
			<xsd:extension base="xsd:normalizedString">
				<xsd:attribute name="listID" type="xsd:normalizedString"/>
				<xsd:attribute name="listURI" type="xsd:anyURI"/>
			</xsd:extension>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:complexType name="SimpleIdentifierType">
		<xsd:simpleContent>
			<xsd:extension base="xsd:normalizedString">
				<xsd:attribute name="schemeID" type="xsd:normalizedString"/>
			</xsd:extension>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:complexType name="SimpleNameType">
		<xsd:simpleContent>
			<xsd:extension base="xsd:string"/>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:complexType name="SimpleQuantityType">
		<xsd:simpleContent>
			<xsd:extension base="xsd:decimal">
				<xsd:attribute name="unitCode" type="xsd:normalizedString" use="required"/>
			</xsd:extension>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:complexType name="SimpleTextType">
		<xsd:simpleContent>
			<xsd:extension base="xsd:string"/>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:complexType name="TextType">
		<xsd:simpleContent>
			<xsd:extension base="xsd:string">
				<xsd:attribute name="languageID" type="xsd:language" use="optional"/>
			</xsd:extension>
		</xsd:simpleContent>
	</xsd:complexType>
	<xsd:simpleType name="ValueType">
		<xsd:restriction base="xsd:decimal"/>
	</xsd:simpleType>
</xsd:schema>


All the best

Stephen Green



>>> "David RR Webber (XML)" <david@drrw.info> 07/02/07 19:07:29 >>>
Steve,

Yes - I feel a little awkward here - on the AJAX front - but anyway -
just some quick points (I do think you need to take a second look at
AJAX - there's some WAY cool stuff - hint see Google's tools...)- 

- AJAX is very much a client-side technology - the server part is as
much or little as you desire.
- You can use AJAX entirely locally - no server - if you desire.
- AJAX is all about XML IMHO!
- it avoids script - because the JS is just an include - those library
routines then read the XML config - and direct the form controls -
event model
- so scripting is easy - can be all at xml level - and of course - tools
write it for you...
- There is really very little difference conceptually between XForms and
AJAX - just deployment model details
- Only Web browser?  Not sure - I'd wager someone has a standalone none
browser deployment!

Anyway - if we can do both - then it plays to both pools of
opportunity...

Cheers, DW

"The way to be is to do" - Confucius (551-472 B.C.)
 

______________________________________________________________________
Please note the new simpler name for our website: http://www.bristol.gov.uk

Our email addresses have also changed - visit http://www.bristol.gov.uk/bigchange for further details.

Sign-up for our email bulletin giving news, have-your-say  and event information at: http://www.bristol.gov.uk/newsdirect 





[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]