General / Allgemeines

In general there is two ways of describing what station tracks are used by a train:

referring to infrastructure elements (station tracks, platform edges), which can describe the elements in more detail, or

using the attribute trackInfo of the element <ocpTT> for track related information

In case the infrastructure part of a railML® file already includes information about station tracks, the first option should be used. The train schedule should refer to the infrastructure data.
The two ways of describing station track usage should not be mixed within the same railML® file.

Using this way of modeling the operation designator of a station track is not provided within a <trainPart>. Instead the infrastructure description is extended by corresponding <track> and <platformEdge> elements. These infrastructure elements are referenced by the <ocpTT>s of a <trainPart>.
The infrastructure elements allow among other things to specify a code (e.g an ID from an infrastructure database) and a name (display name/public name). The code can be provided using the attribute code. The name is specified using name.

A station track is characterized by the fact that its <trackBegin> and <trackEnd> elements refer to the same <ocp> with their ocpRef. Referring to the station track from an <ocpTT> is done using the attribute trackRef.

Specifying a <platformEdge> is optional. That means specifying can be omitted in general or, in case including station track information is wanted, if the <track> does not have a platform edge. It is modeled as a sub element of <track> which implies that for each <platformEdge> a corresponding <track> needs to be provided.
When referring to a platform edge the attribute ref of the <platformEdgeRef> element is used. Since <platformEdgeRef> is a sub element of <stopDescription>, platform edges can only be specified for <ocpTT>s which are scheduled stops of a train.
Specifying the attribute pos of a <platformEdge> is not necessary for all use cases. However in the railML schema it is declared mandatory. In case it is not needed it should be specified as "0".

The attribute trackInfo of <ocpTT> can be used for general information related to the station track used by the <train>. This may be for example a name of a <track> or a <platformEdge> for passenger information. It is not recommended to use this attribute as external key for a <track> or <platformEdge>.