Introduction to the Trans XChange Schema Trans XChange

  • Slides: 21
Download presentation
Introduction to the Trans. XChange Schema (Trans. XChange. Schema. Guide-2. 1 -v-44)

Introduction to the Trans. XChange Schema (Trans. XChange. Schema. Guide-2. 1 -v-44)

What is the Trans. XChange Schema? n n n The schema defines the properties

What is the Trans. XChange Schema? n n n The schema defines the properties of each element (e. g. Service, Operator) in the Trans. XChange model and how each element is related to others. The schema provides a common point of reference for all systems and users of Trans. XChange. The current schema version is 2. 1. The schema is Crown Copyright. The latest version can be obtained from http: //www. transxchange. org. uk/schemas. ht m

Trans. XChange File Formats n n n Trans. XChange is based on an open

Trans. XChange File Formats n n n Trans. XChange is based on an open source software standard known as ‘XML’. XML stands for e. Xtensible Mark-up Language. The elements for describing a bus service in a registration are arranged and presented in an XML document in accordance with the schema. Elements are defined by pairs of ‘tags’, which enclose each piece of textual or numerical information (see next slide). The schema is held separately in. xsd format.

From Schema to XML File

From Schema to XML File

A Short Tour of the Schema n n The Trans. XChange Schema Guide is

A Short Tour of the Schema n n The Trans. XChange Schema Guide is the authoritative guide to the schema. Although a very technical document, it also has a great deal of explanatory content and examples to assist those new to XML. The rest of the presentation gives a short introduction to the structure and the main elements of the schema. Further reference should be made to the Trans. XChange Schema Guide Chapter 6, and to the online examples in XML and PDF format.

Top Level TXC Schema Child elements Root element

Top Level TXC Schema Child elements Root element

The TXC Root Element n n n The root element contains reference information for

The TXC Root Element n n n The root element contains reference information for the file. Some attributes of the Trans. XChange root element include: xml: lang: Default language of document. Default is English. Schema. Version: Trans. XChange schema version identifier used for the document content model. Fixed: must be the schema version, e. g. 2. 0. Mapping. System: Data system to use for mapping references ( OS , Navtech , etc) within the document. Location. System: Data system to use for location coordinate references within the document: WGS 84 or Grid. Must be Grid for registration documents.

Trans. XChange Child Elements n n n The Trans. XChange element has 12 child

Trans. XChange Child Elements n n n The Trans. XChange element has 12 child elements, which may be further subdivided into four groups: Registration Elements: Operator, Registration, (Short. Notice. Registration). Service Supply elements: Service, (Standard. Service, Flexible. Service, Line, Journey. Pattern), Journey. Pattern. Section, Vehicle. Journey. Topographical elements: Stop. Point, Stop. Area, Nptg. Locality, Serviced. Organisation. Route and Network topology elements: Route, Route. Section, Route. Link. Ancillary elements: Supporting. Document.

Registration Elements n Operators: Describes the operator(s) of a service.

Registration Elements n Operators: Describes the operator(s) of a service.

Operators XML Example

Operators XML Example

Registration Elements n Registrations: A collection of Registration elements, each referencing a Service element.

Registration Elements n Registrations: A collection of Registration elements, each referencing a Service element.

Registrations XML Example

Registrations XML Example

Service Supply elements n Services: Definitions of services.

Service Supply elements n Services: Definitions of services.

Services XML Example

Services XML Example

Service Supply Elements n Journey. Pattern Sections: Definitions of Journey Pattern Sections.

Service Supply Elements n Journey. Pattern Sections: Definitions of Journey Pattern Sections.

Journey. Pattern. Sections Example

Journey. Pattern. Sections Example

Service Supply elements n Vehicle. Journeys: Definitions of Vehicle Journeys used in one or

Service Supply elements n Vehicle. Journeys: Definitions of Vehicle Journeys used in one or more services.

Service Supply elements

Service Supply elements

Trans. XChange Child Elements n n n n Topographical elements: Nptg. Localities: Names of

Trans. XChange Child Elements n n n n Topographical elements: Nptg. Localities: Names of NPTG localities used in local stop definitions in the schedule. Stop. Points: Local stop definitions for stops used in services in the schedule. Stop. Areas: Local Stop. Area definitions. Route and Network Topology elements: Routes: Definitions of transport routes. Route. Sections: Definitions of the Route Sections making up all or part of a route.

Trans. XChange Child Elements n n n Other child elements: Serviced. Organisations: Organisations serviced

Trans. XChange Child Elements n n n Other child elements: Serviced. Organisations: Organisations serviced by the schedule, e. g. an LEA, and their working and nonworking days. Supporting. Documents: Additional documents describing the service. Other important schema elements: The Operating. Profile element specifies on which days a service operates. It can be specified on a Vehicle. Journey, a Journey. Pattern and on a Service.

Examples n n Work through some XML examples taken from the Trans. XChange website,

Examples n n Work through some XML examples taken from the Trans. XChange website, starting with the Linear Route. Refer to Section 6 of the Schema Guide for further information on specific elements