1.2.0 • Published 9 years ago

vbb-static v1.2.0

Weekly downloads
4
License
ISC
Repository
github
Last release
9 years ago

vbb-static

vbb-static is a collection of datasets covering the Berlin Brandenburg public transport service (VBB), computed from open GTFS data.

npm version build status dependency status dev dependency status gitter channel

Installing

Warning: This module contains .ndjson files with a total size of roughly 130 megabytes of data.

npm install vbb-static

Usage

const static = require('vbb-static')

This will give you an object with one method for each dataset:

  • agencies( [promised,] filter )
  • lines( [promised,] filter )
  • stations( [promised,] filter )
  • transfers( [promised,] filter )
  • trips( [promised,] filter )
  • schedules( [promised,] filter )

To filter by id, just pass the value.

static.lines(true, 1173).then(…)

To filter by multiple fields, pass them in an object.

static.transfers(true, {
	stationFromId: 9003104,
	stationToId: 9003176
}).then(…)

To get all elements, pass 'all' as the filter.

Examples

static.agencies(true, 'VIB')

returns a promise that will resolve with

[{
	id: 'VIB',
	name: 'Verkehrsbetrieb Potsdam GmbH',
	url: 'http://www.vip-potsdam.de'
}]

static.stations(9042101);

returns an object stream that will emit data once with

{
	id: 9042101,
	name: 'U Spichernstr. (Berlin)',
	latitude: 52.496582,
	longitude: 13.330613,
	weight: 13585
}

Contributing

If you have a question, found a bug or want to propose a feature, have a look at the issues page.

1.2.0

9 years ago

1.1.0

9 years ago

1.0.0

9 years ago

0.12.0

9 years ago

0.11.0

9 years ago

0.10.0

9 years ago

0.9.0

9 years ago

0.8.0

10 years ago

0.7.0

10 years ago

0.6.0

10 years ago

0.5.0

10 years ago

0.4.0

10 years ago

0.3.0

10 years ago

0.2.1

10 years ago

0.2.0

10 years ago

0.1.2

10 years ago

0.1.1

10 years ago

0.1.0

10 years ago