Helpful Classes for the MetOffice Datapoint API. Currently standing at one class, the WeatherCode class. This will hopefully develop into a suite of classes to help speed up development with MetOffice data.
WeatherCode converts the MetOffice DataPoint API weather codes into meaningful strings (as per the documentation). Codes are NA (returns null
) and 0-30, code 4 is an empty code so returns and empty string (not null
though).
$weatherCode = new WeatherCode; print $weatherCode->getTextForCode(30); //prints Thunder
Copyright 2012 NimbleWorks LLP, available to use under the MIT License.