Skip to content

Commit

Permalink
Add AvailabilityRequest from TRIAS (#262)
Browse files Browse the repository at this point in the history
  • Loading branch information
trurlurl authored Jan 16, 2023
1 parent f80f0e2 commit f1531f7
Show file tree
Hide file tree
Showing 11 changed files with 1,361 additions and 598 deletions.
1 change: 1 addition & 0 deletions OJP/OJP_All.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<xs:annotation>
<xs:documentation>OJP/OJP_All.xsd - Includes for all OJP schema files</xs:documentation>
</xs:annotation>
<xs:include schemaLocation="OJP_Availability.xsd"/>
<xs:include schemaLocation="OJP_Common.xsd"/>
<xs:include schemaLocation="OJP_FacilitySupport.xsd"/>
<xs:include schemaLocation="OJP_Fare.xsd"/>
Expand Down
426 changes: 426 additions & 0 deletions OJP/OJP_Availability.xsd

Large diffs are not rendered by default.

26 changes: 26 additions & 0 deletions OJP/OJP_Requests.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -221,4 +221,30 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:annotation>
<xs:documentation>========================================== Availability Request ==========================================</xs:documentation>
</xs:annotation>
<xs:element name="OJPAvailabilityRequest" type="OJPAvailabilityRequestStructure" substitutionGroup="siri:AbstractFunctionalServiceRequest"/>
<xs:complexType name="OJPAvailabilityRequestStructure">
<xs:complexContent>
<xs:extension base="AbstractOJPServiceRequestStructure">
<xs:sequence>
<xs:group ref="AvailabilityRequestGroup"/>
<xs:element ref="siri:Extensions" minOccurs="0"/>
</xs:sequence>
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:element name="OJPAvailabilityDelivery" type="OJPAvailabilityDeliveryStructure" substitutionGroup="siri:AbstractFunctionalServiceDelivery"/>
<xs:complexType name="OJPAvailabilityDeliveryStructure">
<xs:complexContent>
<xs:extension base="siri:AbstractServiceDeliveryStructure">
<xs:sequence>
<xs:group ref="ServiceResponseContextGroup"/>
<xs:group ref="AvailabilityResponseGroup"/>
<xs:element ref="siri:Extensions" minOccurs="0"/>
</xs:sequence>
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:schema>
6 changes: 6 additions & 0 deletions OJP/OJP_Utility.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,12 @@
</xs:annotation>
<xs:restriction base="xs:normalizedString"/>
</xs:simpleType>
<xs:simpleType name="EMailAddressType">
<xs:annotation>
<xs:documentation>Type definition for e-mail addresses.</xs:documentation>
</xs:annotation>
<xs:restriction base="xs:normalizedString"/>
</xs:simpleType>
<xs:complexType name="InternationalTextStructure">
<xs:annotation>
<xs:documentation>[a restricted view of ALTERNATIVE NAME in TMv6] alternative identified text to be used in specified languages.</xs:documentation>
Expand Down
1,317 changes: 726 additions & 591 deletions docs/generated/index.html

Large diffs are not rendered by default.

18 changes: 11 additions & 7 deletions docs/schema-collection.xml
Original file line number Diff line number Diff line change
@@ -1,19 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<schema-collection xmlns:xi="http://www.w3.org/2001/XInclude">
<!--
The order of includes defines the order in the generated documentation
-->
<xi:include href="../OJP.xsd"/>
<xi:include href="../OJP/OJP_Common.xsd"/>
<xi:include href="../OJP/OJP_FacilitySupport.xsd"/>
<xi:include href="../OJP/OJP_Requests.xsd"/>
<xi:include href="../OJP/OJP_RequestSupport.xsd"/>
<xi:include href="../OJP/OJP_Fare.xsd"/>
<xi:include href="../OJP/OJP_FareSupport.xsd"/>
<xi:include href="../OJP/OJP_JourneySupport.xsd"/>
<xi:include href="../OJP/OJP_ModesSupport.xsd"/>
<xi:include href="../OJP/OJP_Places.xsd"/>
<xi:include href="../OJP/OJP_PlaceSupport.xsd"/>
<xi:include href="../OJP/OJP_Requests.xsd"/>
<xi:include href="../OJP/OJP_RequestSupport.xsd"/>
<xi:include href="../OJP/OJP_SituationSupport.xsd"/>
<xi:include href="../OJP/OJP_StopEvents.xsd"/>
<xi:include href="../OJP/OJP_TripInfo.xsd"/>
<xi:include href="../OJP/OJP_Trips.xsd"/>
<xi:include href="../OJP/OJP_JourneySupport.xsd"/>
<xi:include href="../OJP/OJP_Availability.xsd"/>
<xi:include href="../OJP/OJP_Common.xsd"/>
<xi:include href="../OJP/OJP_FacilitySupport.xsd"/>
<xi:include href="../OJP/OJP_ModesSupport.xsd"/>
<xi:include href="../OJP/OJP_SituationSupport.xsd"/>
<xi:include href="../OJP/OJP_Utility.xsd"/>
</schema-collection>
70 changes: 70 additions & 0 deletions examples/function/OJPAvailabilityRequest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
<?xml version="1.0" encoding="UTF-8"?>
<OJP xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.siri.org.uk/siri" xmlns:ojp="http://www.vdv.de/ojp" version="1.1-dev" xsi:schemaLocation="http://www.siri.org.uk/siri ../../OJP.xsd">
<OJPRequest>
<ServiceRequest>
<RequestTimestamp>2020-01-19T12:00:00Z</RequestTimestamp>
<RequestorRef>MyClient</RequestorRef>
<ojp:OJPAvailabilityRequest>
<RequestTimestamp>2020-01-19T12:00:00Z</RequestTimestamp>
<MessageIdentifier>231231-231</MessageIdentifier>
<ojp:PublicTransport>
<ojp:PickUpLocation>
<ojp:CallPlace>
<ojp:StopPlaceRef>ch:1:sloid:7000</ojp:StopPlaceRef>
<ojp:Name>
<ojp:Text>origin</ojp:Text>
</ojp:Name>
</ojp:CallPlace>
<ojp:Order>7</ojp:Order>
</ojp:PickUpLocation>
<ojp:SetDownLocation>
<ojp:CallPlace>
<ojp:GeoPosition>
<Longitude>20.12121</Longitude>
<Latitude>30.134123</Latitude>
<Precision>20</Precision>
</ojp:GeoPosition>
<ojp:Name>
<ojp:Text>destiniation</ojp:Text>
</ojp:Name>
<ojp:AllowedSystemId>sbb</ojp:AllowedSystemId>
</ojp:CallPlace>
<ojp:ServiceArrival>
<ojp:TimetabledTime>2022-10-19T12:00:00Z</ojp:TimetabledTime>
<ojp:EstimatedTimeLow>2022-10-19T11:55:00Z</ojp:EstimatedTimeLow>
<ojp:EstimatedTimeHigh>2022-10-19T12:10:00Z</ojp:EstimatedTimeHigh>
</ojp:ServiceArrival>
<ojp:Order>10</ojp:Order>
<ojp:RequestStop>true</ojp:RequestStop>
<ojp:UnplannedStop>false</ojp:UnplannedStop>
<ojp:NotServicedStop>false</ojp:NotServicedStop>
</ojp:SetDownLocation>
<LineRef>ch:1:slnid:102301231</LineRef>
<ojp:Mode>
<ojp:PtMode>bus</ojp:PtMode>
<BusSubmode>demandAndResponseBus</BusSubmode>
</ojp:Mode>
<ojp:ProductCategory>
<ojp:ProductCategoryRef>NB</ojp:ProductCategoryRef>
</ojp:ProductCategory>
<ojp:PublishedServiceName>
<ojp:Text>NB 1</ojp:Text>
</ojp:PublishedServiceName>
<VehicleRef>1293912-1231</VehicleRef>
<ojp:OperatorRef>ch:1:sboid:13123</ojp:OperatorRef>
</ojp:PublicTransport>
<ojp:MobilityUser>
<ojp:Age>19</ojp:Age>
<ojp:WheelchairUser>true</ojp:WheelchairUser>
<ojp:NoSingleStep>true</ojp:NoSingleStep>
<ojp:NoStairs>true</ojp:NoStairs>
<ojp:LevelEntrance>true</ojp:LevelEntrance>
<ojp:WalkSpeed>70</ojp:WalkSpeed>
<ojp:AdditionalTransferTime>PT2M</ojp:AdditionalTransferTime>
</ojp:MobilityUser>
<ojp:EarliestDepartureTime>2022-10-19T11:30:00Z</ojp:EarliestDepartureTime>
<ojp:LatestArrivalTime>2022-10-19T12:10:00Z</ojp:LatestArrivalTime>
</ojp:OJPAvailabilityRequest>
</ServiceRequest>
</OJPRequest>
</OJP>
29 changes: 29 additions & 0 deletions examples/function/OJPAvailabilityRequest_1.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<ojp:OJPAvailabilityRequest xmlns:ojp="http://www.vdv.de/ojp" xmlns:siri="http://www.siri.org.uk/siri" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.siri.org.uk/siri ../../OJP.xsd">
<siri:RequestTimestamp>2022-12-12T11:46:00Z</siri:RequestTimestamp>
<ojp:PublicTransport>
<ojp:PickUpLocation>
<ojp:CallPlace>
<siri:StopPointRef>de:05766:2317:0:1</siri:StopPointRef>
<ojp:Name>
<ojp:Text>Kt-Kalldorf, Winterberg</ojp:Text>
</ojp:Name>
</ojp:CallPlace>
<ojp:ServiceDeparture>
<ojp:TimetabledTime>2022-12-12T11:46:00Z</ojp:TimetabledTime>
</ojp:ServiceDeparture>
</ojp:PickUpLocation>
<ojp:SetDownLocation>
<ojp:CallPlace>
<siri:StopPointRef>de:05766:3437:0:2</siri:StopPointRef>
<ojp:Name>
<ojp:Text>Kt-Stemmen, Elfenborner Weg</ojp:Text>
</ojp:Name>
</ojp:CallPlace>
<ojp:ServiceArrival>
<ojp:TimetabledTime>2022-12-12T12:02:00Z</ojp:TimetabledTime>
</ojp:ServiceArrival>
</ojp:SetDownLocation>
</ojp:PublicTransport>
<ojp:MobilityUser/>
</ojp:OJPAvailabilityRequest>
29 changes: 29 additions & 0 deletions examples/function/OJPAvailabilityRequest_2.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<ojp:OJPAvailabilityRequest xmlns:ojp="http://www.vdv.de/ojp" xmlns:siri="http://www.siri.org.uk/siri" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.siri.org.uk/siri ../../OJP.xsd">
<siri:RequestTimestamp>2022-12-12T11:46:00Z</siri:RequestTimestamp>
<ojp:PublicTransport>
<ojp:PickUpLocation>
<ojp:CallPlace>
<siri:StopPointRef>de:05766:2317:0:1</siri:StopPointRef>
<ojp:Name>
<ojp:Text>Kt-Kalldorf, Winterberg</ojp:Text>
</ojp:Name>
</ojp:CallPlace>
<ojp:ServiceDeparture>
<ojp:TimetabledTime>2022-12-14T09:46:00Z</ojp:TimetabledTime>
</ojp:ServiceDeparture>
</ojp:PickUpLocation>
<ojp:SetDownLocation>
<ojp:CallPlace>
<siri:StopPointRef>de:05766:3437:0:2</siri:StopPointRef>
<ojp:Name>
<ojp:Text>Kt-Stemmen, Elfenborner Weg</ojp:Text>
</ojp:Name>
</ojp:CallPlace>
<ojp:ServiceArrival>
<ojp:TimetabledTime>2022-12-14T10:02:00Z</ojp:TimetabledTime>
</ojp:ServiceArrival>
</ojp:SetDownLocation>
</ojp:PublicTransport>
<ojp:MobilityUser/>
</ojp:OJPAvailabilityRequest>
10 changes: 10 additions & 0 deletions examples/function/OJPAvailabilityResponse notOK.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<ojp:OJPAvailabilityDelivery xmlns:ojp="http://www.vdv.de/ojp" xmlns:siri="http://www.siri.org.uk/siri" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.siri.org.uk/siri ../../OJP.xsd">
<siri:ResponseTimestamp>2001-12-17T09:30:47Z</siri:ResponseTimestamp>
<siri:Status>false</siri:Status>
<siri:ErrorCondition>
<siri:OtherError>
<siri:ErrorText>Anfrage konnte nicht verarbeitet werden</siri:ErrorText>
</siri:OtherError>
</siri:ErrorCondition>
</ojp:OJPAvailabilityDelivery>
27 changes: 27 additions & 0 deletions examples/function/OJPAvailabilityResponse_OK.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<ojp:OJPAvailabilityDelivery xmlns:ojp="http://www.vdv.de/ojp" xmlns:siri="http://www.siri.org.uk/siri" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.siri.org.uk/siri ../../OJP.xsd">
<siri:ResponseTimestamp>2001-12-17T09:30:47Z</siri:ResponseTimestamp>
<ojp:AvailabilityResult>
<ojp:PublicTransport>
<ojp:PickUpLocation>
<ojp:CallPlace>
<siri:StopPointRef>de:05766:2317</siri:StopPointRef>
<ojp:Name>
<ojp:Text>Winterberg/Kalldorf</ojp:Text>
</ojp:Name>
</ojp:CallPlace>
</ojp:PickUpLocation>
<ojp:SetDownLocation>
<ojp:CallPlace>
<siri:StopPointRef>de:05766:3437</siri:StopPointRef>
<ojp:Name>
<ojp:Text>Elfenborner Weg/Stemmen (Kalletal)</ojp:Text>
</ojp:Name>
</ojp:CallPlace>
<ojp:ServiceArrival>
<ojp:TimetabledTime>2022-12-14T11:02:00+01:00</ojp:TimetabledTime>
</ojp:ServiceArrival>
</ojp:SetDownLocation>
</ojp:PublicTransport>
</ojp:AvailabilityResult>
</ojp:OJPAvailabilityDelivery>

0 comments on commit f1531f7

Please sign in to comment.