Services_Weather::service

Services_Weather::service() – Factory for creating the services-objects

Synopsis

require_once '/Weather.php';

PEAR_Error|object& Services_Weather::service ( string $service , array $options = null )

Description

Usable keys for the options array are:

  • debug enables debugging output

--- Common Options

  • cacheType defines what type of cache to use

  • cacheOptions passes cache options

  • unitsFormat use (US)-standard, metric or custom units

  • customUnitsFormat defines the customized units format

  • httpTimeout sets timeout for HTTP requests

  • dateFormat string to use for date output

  • timeFormat string to use for time output

--- EJSE Options

  • none

--- GlobalWeather Options

  • none

--- METAR Options

  • dsn String for defining the DB connection

  • dbOptions passes DB options

  • source http, ftp or file - type of data-source

  • sourcePath where to look for the source, URI or filepath

--- weather.com Options

  • partnerID You'll receive these keys after registering

  • licenseKey with the weather.com XML-service

Parameter

string $service

array $options

Throws

throws PEAR_Error

throws PEAR_Error::SERVICES_WEATHER_ERROR_SERVICE_NOT_FOUND

Note

This function can not be called statically.