Home » railML newsgroups » railML.infrastructure » More detailed 'speed change' definitions
Required 'id' attributes (was: More detailed 'speed change' definitions) [message #420 is a reply to message #322] Wed, 07 November 2012 14:25 Go to previous messageGo to previous message
Susanne Wunsch railML is currently offline  Susanne Wunsch railML
Messages: 0
Registered: January 2020
Hello Dirk and others,

The following aspect was quite overseen, sorry for that.

I changed the follow-up to railML.misc because of the more general
topic.

Dirk Bräuer <dirkbraeuer(at)irfpde> writes:
> <speedChange id="sc3"...>
>
> Can we have the ‚id’ of a speed change as an optional attribute? Since
> we have many, many speed changes and seldom the need to refer to them
> I do (optionally) want to save some space and effort.

* The "id" attribute provides good facilities to fetch single elements
(with its attributes and sub-elements) from an XML file irrespective
of an existing reference in the XML file.

* There are other often-used XML standards that use the same mechanism:

e.g. GML (Geographic Markup Language)

<attribute name="id" type="ID">
<annotation>
<documentation>The attribute gml:id supports provision of a handle
for the XML element representing a GML Object. Its use is
mandatory for all GML objects. It is of XML type ID, so is
constrained to be unique in the XML document within which it
occurs.</documentation>
</annotation>
</attribute>

<complexType name="AbstractGMLType" abstract="true">
<sequence>
<group ref="gml:StandardObjectProperties"/>
</sequence>
<attribute ref="gml:id" use="required"/>
</complexType>


This attribute is required for all GML objects irrespective any
reference.

A huge amount of XML Schemas in the Geographic field of application
base on the above mentioned XML Schema.

* It is already a very smart implementation for identification.

The following example shows up a typical alternative from the banking
sector:

<act:id type="guid">aa671349a0befafcfff1773e42eb8a49</act:id>

* There are algorithms for different programming languages for the
ID-generation in general.

e.g. generate-id() in XPath (staying at the XML-world) ;-)

* The _required_ attribute may only be changed into "optional" for the
next major release.

I hope it clarifies the issue a bit.

Kind regards...
Susanne

Crosspost & Followup-To: railML.misc

--
Susanne Wunsch
Schema Coordinator: railML.common
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re-factoring of <infraAttributes>
Next Topic: Hierarchy of overlaying speed profiles and National vs. Generic speed profiles.
Goto Forum:
  


Current Time: Fri Apr 19 16:30:25 CEST 2024