libpublictransportation  0.1.52 (snapshot)
Extensible public transportation library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Macros Pages
publictransportation

publictransportation is an application that deals with public transportation, providing realtime information, timetable and other features.

Instead of being yet another monolitic public transportation app, publictransportation is splitted into a library that is designed to be extensible, an application that is only a frontend of the library, and several plugins or even helper scripts, that are used to provide information about public transportation companies.

Design

libpublictransportation is designed to be flexible and to load information from several sources. It provides a API that allows interfacing with nearly all programming languages. It also provides a helper app, that is called a provider, and that can load C++/Qt plugin to retrieve information.

Extending libpublictransportation can be done in two ways

  • write a program or a script that profits from the DBus API
  • write a provider plugin and profit from the C++ API.

publictransportation manages providers and scripts and launch them when needed, and communicate with DBus to them. This have several advantages, notably a fully asynchronous process and a very simple architecture.

Future works

Due to the hard dependency on DBus, it is impossible to make publictransportation on non-Linux systems. However, the DBus part is separated from the logic and it might be possible to extend publictransportation to work using sockets, and then, on other platforms. However scripts using the DBus API won't work.