Dear Jan,
you can model linear locations spanning over several associated NetElements also without the attribute @keepsOrientation.
Let's take the element <line> in the railML Simple Example. It spans over three NetElements (in mesoscopic level). Now, let's assume that the NetElement in the middle is oriented in opposite direction. If you model the location with intrinsic coordinates, the source code looks like this:
<linearLocation id="lin01_lloc01" applicationDirection="both">
<associatedNetElement netElementRef="ne_a11" intrinsicCoordBegin="0" intrinsicCoordEnd="1" />
<associatedNetElement netElementRef="ne_x11" intrinsicCoordBegin="1" intrinsicCoordEnd="0" />
<associatedNetElement netElementRef="ne_b11" intrinsicCoordBegin="0" intrinsicCoordEnd="1" />
</linearLocation>
If you want to use the intrinsic positioning system (usable for length and distance measurements) instead of intrinsic coordinates, the source code looks like this:
<linearLocation id="lin01_lloc02" applicationDirection="both">
<associatedNetElement netElementRef="ne_a11">
<linearCoordinateBegin positioningSystemRef="ips" measure="0.0"/>
<linearCoordinateEnd positioningSystemRef="ips" measure="700.0"/>
</associatedNetElement>
<associatedNetElement netElementRef="ne_x11">
<linearCoordinateBegin positioningSystemRef="ips" measure="3600.0"/>
<linearCoordinateEnd positioningSystemRef="ips" measure="0.0"/>
</associatedNetElement>
<associatedNetElement netElementRef="ne_b11">
<linearCoordinateBegin positioningSystemRef="ips" measure="0.0"/>
<linearCoordinateEnd positioningSystemRef="ips" measure="700.0"/>
</associatedNetElement>
</linearLocation>
Please use one of these two approaches for modelling the linear location of the line. In addition, you are free to add the mileage (line kilometer reference system) as another coordinate system. The resulting source code may look like this (as you see, this mileage is independent from the NetElement orientation):
<linearLocation id="lin01_lloc03" applicationDirection="both">
<associatedNetElement netElementRef="ne_a11">
<linearCoordinateBegin positioningSystemRef="lps01" measure="0.0"/>
<linearCoordinateEnd positioningSystemRef="lps01" measure="700.0"/>
</associatedNetElement>
<associatedNetElement netElementRef="ne_x11">
<linearCoordinateBegin positioningSystemRef="lps01" measure="700.0"/>
<linearCoordinateEnd positioningSystemRef="lps01" measure="4300.0"/>
</associatedNetElement>
<associatedNetElement netElementRef="ne_b11">
<linearCoordinateBegin positioningSystemRef="lps01" measure="4300.0"/>
<linearCoordinateEnd positioningSystemRef="lps01" measure="5000.0"/>
</associatedNetElement>
</linearLocation>
Does this sound fine for you? Please give us a feedback or write your further questions.
Best regards
Christian