Skip to content

Conversation

@Robbendebiene
Copy link
Contributor

@Robbendebiene Robbendebiene commented Jul 31, 2025

I noticed that EquipmentRef can be assigned to WheelchairVehicleEquipment and AccessVehicleEquipment. This seemed wrong to me. My guess is that the ActualVehicleEquipmentGroup shouldn't be part of them.

Currently things like this can be done:

<ActualVehicleEquipment>
   <Units>3</Units>
   <AccessVehicleEquipmentRef ref="a"/>
</ActualVehicleEquipment>

<AccessVehicleEquipment version="any" id="a">
   <Units>3</Units><!-- feels wrong -->
   <BedEquipmentRef ref="x"/><!-- feels wrong -->
   <!-- equipment properties here -->
</AccessVehicleEquipment>

I think only this should be possible

<ActualVehicleEquipment>
   <Units>3</Units>
   <AccessVehicleEquipmentRef ref="a"/>
</ActualVehicleEquipment>

<AccessVehicleEquipment version="any" id="a">
   <!-- equipment properties here -->
</AccessVehicleEquipment>

The commit states that these changes are originally from @nick-knowles

@skinkie
Copy link
Contributor

skinkie commented Jul 31, 2025

I don't think this is the right solution. I think that the cause is more in the direction of the subsitution group...

@ue71603
Copy link
Contributor

ue71603 commented Jul 31, 2025

@skinkie you disagree it seems

@Robbendebiene
Copy link
Contributor Author

@skinkie Can you please elaborate what substitution group you are referring to (I assume substitutionGroup="PassengerEquipment") and how it would solve the problem?

In my solution I probably would also have to change <xsd:extension base="ActualVehicleEquipment_VersionStructure"> for WheelchairVehicleEquipment_VersionStructure and AccessVehicleEquipment_VersionStructure. Though to be honest, I haven't understood the usage of X_VersionStructure yet.

@skinkie
Copy link
Contributor

skinkie commented Jul 31, 2025

@Robbendebiene therefore I want to have @Aurige or @nick-knowles comment here.

@Aurige
Copy link
Contributor

Aurige commented Aug 4, 2025

This is coming from Transmodel ... If I remember well the key point of the ActualVehicleEquipment is to connect the Equipment to a VehicleType, but as the ActualVehicleEquipment can be standalone, it also needs to be able to refer an Equipment (not to be used when already embedded in an Equipment). But I'm puzzled by the VehicleType relation (instead of Vehicle) in the XSD ...
So changes here would require a larger group discussion
image

@Robbendebiene
Copy link
Contributor Author

I feel like there might be a small misunderstanding, so I just want to restate that the problem I'm reporting is more about AccessVehicleEquipment and WheelchairVehicleEquipment than about ActualVehicleEquipment.

Simply speaking I think AccessVehicleEquipment and WheelchairVehicleEquipment should not incorporate any properties from ActualVehicleEquipment (like the EquipmentRef). Instead ActualVehicleEquipment should be used to reference AccessVehicleEquipment and WheelchairVehicleEquipment.

I think ActualVehicleEquipment is fine except that it doesn't make sense to allow it in ResourceFrame/equipments and that there is a small inconsistency in what actualVehicleEquipments can contain which I described here: #875

But I'm puzzled by the VehicleType relation (instead of Vehicle) in the XSD ...

That is actually a question I had as well which I raised here #875 (comment) So perhaps it makes sense to discuss these topics together.

Aurige
Aurige previously approved these changes Aug 26, 2025
@TuThoThai
Copy link
Collaborator

Happy to approve if @skinkie running the script confirms that no examples are broken

@skinkie
Copy link
Contributor

skinkie commented Aug 26, 2025

THIS FAILS.

examples/functions/timetable/Netex_21_Rail_NetworkTimetable_eurostar.xml:11730: Schemas validity error : Element '{http://www.netex.org.uk/netex}AccessibilityAssessment': This element is not expected. Expected is one of ( {http://www.netex.org.uk/netex}validityConditions, {http://www.netex.org.uk/netex}ValidBetween, {http://www.netex.org.uk/netex}alternativeTexts, {http://www.netex.org.uk/netex}keyList, {http://www.netex.org.uk/netex}privateCodes, {http://www.netex.org.uk/netex}Extensions, {http://www.netex.org.uk/netex}BrandingRef, {http://www.netex.org.uk/netex}Name, {http://www.netex.org.uk/netex}PrivateCode, {http://www.netex.org.uk/netex}PublicCode ).

Where it fails:

<WheelchairVehicleEquipment version="any" id="est:WheelchairVehicleEquipment:sfe_veheq_trne_LP01_10_02">
        <AccessibilityAssessment version="any" id="est:acaa_sfe_veheq_trne_LP01_10_02">
                <MobilityImpairedAccess>true</MobilityImpairedAccess>
                <suitabilities>
                        <Suitability id="est:acsst_sfe_veheq_trne_LP01_10_02">
                                <MobilityNeed>wheelchair</MobilityNeed>
                                <Suitable>notSuitable</Suitable>
                        </Suitability>
                </suitabilities>
        </AccessibilityAssessment>
        <NumberOfWheelchairAreas>1</NumberOfWheelchairAreas>
        <WidthOfAccessArea>1.0</WidthOfAccessArea>
        <CompanionSeat>true</CompanionSeat>
</WheelchairVehicleEquipment>

@TuThoThai
Copy link
Collaborator

THIS FAILS.

examples/functions/timetable/Netex_21_Rail_NetworkTimetable_eurostar.xml:11730: Schemas validity error : Element '{http://www.netex.org.uk/netex}AccessibilityAssessment': This element is not expected. Expected is one of ( {http://www.netex.org.uk/netex}validityConditions, {http://www.netex.org.uk/netex}ValidBetween, {http://www.netex.org.uk/netex}alternativeTexts, {http://www.netex.org.uk/netex}keyList, {http://www.netex.org.uk/netex}privateCodes, {http://www.netex.org.uk/netex}Extensions, {http://www.netex.org.uk/netex}BrandingRef, {http://www.netex.org.uk/netex}Name, {http://www.netex.org.uk/netex}PrivateCode, {http://www.netex.org.uk/netex}PublicCode ).

Where it fails:

<WheelchairVehicleEquipment version="any" id="est:WheelchairVehicleEquipment:sfe_veheq_trne_LP01_10_02">
        <AccessibilityAssessment version="any" id="est:acaa_sfe_veheq_trne_LP01_10_02">
                <MobilityImpairedAccess>true</MobilityImpairedAccess>
                <suitabilities>
                        <Suitability id="est:acsst_sfe_veheq_trne_LP01_10_02">
                                <MobilityNeed>wheelchair</MobilityNeed>
                                <Suitable>notSuitable</Suitable>
                        </Suitability>
                </suitabilities>
        </AccessibilityAssessment>
        <NumberOfWheelchairAreas>1</NumberOfWheelchairAreas>
        <WidthOfAccessArea>1.0</WidthOfAccessArea>
        <CompanionSeat>true</CompanionSeat>
</WheelchairVehicleEquipment>

Interesting, it is a modelling way we do not use in France as for us it is a bit redundant. If you are describing a WheelchairVehicleEquipment, we do not use AccessibilityAssessment 😄

@Robbendebiene
Copy link
Contributor Author

So there are two options:

  1. Deprecate the properties inherited from ActualVehicleEquipmentGroup for WheelchairVehicleEquipment and AccessVehicleEquipment instead of removing them because they are on master and also used in an example.
  2. Adjust the example and keep removing these properties. This would break backwards compatibility but on the other hand it is a bug which was never intended to work.

Which way to go?

@Robbendebiene
Copy link
Contributor Author

The online view of Transmodel 2021 (https://transmodel-cen.eu/model/) also contains the inheritance of ActualVehicleEquipment. So this at least explains why it is in NeTEx as well.

grafik

The question basically boils down to:
Should AccessibilityAssessment be on the equipment definition as well (like it is e.g. for SanitaryEquipment) or should it only be on ActualVehicleEquipment?
From a DeckPlan perspective one always requires an ActualVehicleEquipment so it is not needed in this area.
However if the equipment is assigned via an VehicleEquipmentProfile or directly to a Trailing/TractiveElementType (as in the failing example) referencing an ActualVehicleEquipment which in turn references another equipment feels odd.

@skinkie
Copy link
Contributor

skinkie commented Sep 1, 2025

I am all for deprecating erronous modeling.

@Robbendebiene
Copy link
Contributor Author

I added a separate group to annotate the properties as deprecated.

@TuThoThai TuThoThai added this to the netex_2.1 milestone Sep 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants