Class Wunderground

Description

Located in /wunderground.php (line 2)


	
			
Variable Summary
 bool|string $cache_dir
 object $forecast_xml
 float $lat
 float $lon
 float $msl
Method Summary
 void get_forecast (int $epoc)
 void get_forecast_data ([ $force = FALSE])
 void get_forecast_steps (int $start,  $end, [int $step = 3600])
 void __call (string $method, [array $args = null])
Variables
bool|string $cache_dir = FALSE (line 26)

What caching directory to use

Set this to FALSE to not use any caching

mixed $cache_expiry = 3600 (line 32)

The period of life for a cache file

Files older than this will be removed on subsequent data requests

object $forecast_xml (line 38)

The last XML object of a forecast request

float $lat = 60.10 (line 13)

The latitude of the area we are querying

float $lon = 9.58 (line 7)

The longitude of the area we are querying

float $msl = 70 (line 19)

The distance above sea-level (in meters) of the area we are querying

Methods
get_forecast (line 88)

Get the forecast of a specific date

The date will be rounded backwards to the beginning of the given hour So 2011-01-01 15:43 becomes 2011-01-01 15:00

void get_forecast (int $epoc)
  • int $epoc: The epoc of the date to retrieve
get_forecast_data (line 58)

Perform a retrieval for the Wunderground forecast information

void get_forecast_data ([ $force = FALSE])
  • $force
get_forecast_steps (line 113)

Retrieves a range of forecasts from a beginning epoc to the end

Times are rounded in the same was as get_forecast()

void get_forecast_steps (int $start,  $end, [int $step = 3600])
  • int $start: The epoc end point
  • int $step: What value to step by. The default is one hour @ see get_forecast()
  • $end
__call (line 46)

Magic method binder to dumbly set the above variables

e.g. set_cache_dir is bound to $this->cache_dir = $x

void __call (string $method, [array $args = null])
  • string $method: The method being called
  • array $args: The arguments being passed to the magic method

Documentation generated on Sun, 15 May 2011 13:18:05 +1000 by phpDocumentor 1.4.3