0.0.2 • Published 12 years ago
utsire v0.0.2
utsire
A rudimentary parser for the Shipping Forecast, as issued by the Met Office on
behalf of the Maritime and Coastguard Agency at 0600 today.
Usage
var utsire = require('utsire')
utsire.get(function(forecast) {
console.log(forecast.gales)
})Structure
utsire.get(callback) is the only function. It returns an object with the
following properties:
synopsis: an object containing atimeand acontentstring, the former containing the time of the synopsis, and the latter containing the general synopsis itself.areas: an object containing objects containing Area Forecasts, keyed to each area (e.g."Viking", which in turn containsprecipitation,wind,seastateandvisibilitystrings, as well as asharedobject containing the list of areas that have identical forecasts.header: always"Shipping forecast".gales: an array of area names that currently have gale warnings in force.
0.0.2
12 years ago