Skip to content

Commit

Permalink
Update trip refinement (#298)
Browse files Browse the repository at this point in the history
* improved refinement
* next change. all legs can be refined too
* better example an fixed PurchaseMoment
* Removed space in excess
  • Loading branch information
ue71603 authored Apr 5, 2023
1 parent dd4e176 commit 0ff73ed
Show file tree
Hide file tree
Showing 5 changed files with 436 additions and 10 deletions.
2 changes: 1 addition & 1 deletion OJP/OJP_JourneySupport.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@
</xs:complexType>
<xs:complexType name="TripLocationStructure">
<xs:annotation>
<xs:documentation>A trip location represents the current logical position of a journey service. It can be used similarly to a place e.g. for starting a new trip requests from within this service. A trip location does not(!) describe the relative position of a traveller within a vehicle, e.g. the seat.</xs:documentation>
<xs:documentation>A trip location represents the current logical position of a journey service. It can be used similarly to a place e.g. for starting a new trip request from within this service. A trip location does not(!) describe the relative position of a traveller within a vehicle, e.g. the seat.</xs:documentation>
</xs:annotation>
<xs:sequence>
<xs:element ref="OperatingDayRef"/>
Expand Down
34 changes: 31 additions & 3 deletions OJP/OJP_Trips.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@
<xs:documentation>Fare and fare product information for this trip as a whole or parts of it.</xs:documentation>
</xs:annotation>
</xs:element>
<xs:element name="IsAlternativeOption" type="xs:boolean" minOccurs="0" default="false">
<xs:element name="IsAlternativeOption" type="xs:boolean" default="false" minOccurs="0">
<xs:annotation>
<xs:documentation>When the result is an alternative option from IncludeAlternativeOptions, then the flag should be set to true. If it is an alternative option this means that the server decided to add this result for its own reasons: e.g. to push a certain trip leg, because it believes that it might better suit at least some possible customers. Such options are not an optimal fit to the criteria that were in the request. The client may therefore disregard such results depending on the use case.</xs:documentation>
</xs:annotation>
Expand Down Expand Up @@ -1462,6 +1462,18 @@
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="TripRefinementDataFilterGroup">
<xs:annotation>
<xs:documentation>Request data filters for Refinement</xs:documentation>
</xs:annotation>
<xs:sequence>
<xs:element name="OperatorFilter" type="OperatorFilterStructure" minOccurs="0">
<xs:annotation>
<xs:documentation>Transport operators to include/exclude.</xs:documentation>
</xs:annotation>
</xs:element>
</xs:sequence>
</xs:group>
<xs:complexType name="TripRefineParamStructure">
<xs:annotation>
<xs:documentation>Trip refinement request parameter structure.</xs:documentation>
Expand All @@ -1472,16 +1484,22 @@
<xs:documentation>If true, then the request may contain object references from another system. Default is FALSE.</xs:documentation>
</xs:annotation>
</xs:element>
<xs:element name="RefineLegRef" type="xs:NMTOKEN" maxOccurs="unbounded">
<xs:element name="RefineLegRef" type="xs:NMTOKEN" minOccurs="0" maxOccurs="unbounded">
<xs:annotation>
<xs:documentation>Refers to a leg to be refined by the server.</xs:documentation>
<xs:documentation>Refers to the legs to be refined by the server. If none is given, then all legs are open for refinement (depending if the relevant system can refine them).</xs:documentation>
</xs:annotation>
</xs:element>
<xs:element name="SystemId" type="xs:normalizedString" minOccurs="0">
<xs:annotation>
<xs:documentation>System reference to use for the refinement. If not specified the origin systems of each leg are used for the refinement.</xs:documentation>
</xs:annotation>
</xs:element>
<xs:element name="UseRealtimeData" type="UseRealtimeDataEnumeration" default="full" minOccurs="0">
<xs:annotation>
<xs:documentation>Usage of real-time data in refinement. Default is "full".</xs:documentation>
</xs:annotation>
</xs:element>
<xs:group ref="TripRefinementDataFilterGroup"/>
<xs:group ref="TripContentFilterGroup"/>
<xs:element name="FareParam" type="FareParamStructure" minOccurs="0">
<xs:annotation>
Expand Down Expand Up @@ -1639,6 +1657,16 @@
<xs:documentation>Indicated legs do not exist.</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="REFINE_OBJECTNOTFOUND">
<xs:annotation>
<xs:documentation>The object to be refined could not be found in the database of the responding system or could not be found unequivocally.</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="REFINE_PROFILENOTSUPPORTED">
<xs:annotation>
<xs:documentation>Refinement does not support the hiking or cycling profile.</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="TRIP_OTHER">
<xs:annotation>
<xs:documentation>A problem has occurred that does not have a specific problem type.</xs:documentation>
Expand Down
Loading

0 comments on commit 0ff73ed

Please sign in to comment.