NAME
Weather::Com::DayPart - class representing daytime or night part of a forecast
SYNOPSIS
[...]
my @locations = $weather_finder->find('Heidelberg');
my $forecast = $locations[0]->forecast();
my $tomorrow_night = $forecast->day(1)->night();
print "Forecast for tomorrow night:\n";
print " - conditions will be ", $tomorrow_night->conditions(), "\n";
print " - humidity will be ", $tomorrow_night->humidity(), "\%\n";
print " - wind speed will be ", $tomorrow_night->wind()->speed(), "km/h\n";
DESCRIPTION
Via Weather::Com::DayPart objects one can access the daytime or night part of a Weather::Com::DayForecast.
This class will not be updated automatically with each call to one of its methods. You need to call a method of your Weather::Com::Forecast object to get updated objects.
CONSTRUCTOR
You usually would not construct an object of this class yourself. This is implicitely done when you call the day()
or night()
method of a Weather::Com::DayForecast object.
METHODS
type()
Will return day or night.
conditions()
Will return a textual description of the forecasted conditions.
humidity()
Will return the humidity.
icon()
Will return the icon number of the icon describing the forecasted weather.
precipitation()
Will return the percentage chance of precipitation.
wind()
Will return a Weather::Com::Wind object.
AUTHOR
Thomas Schnuecker, <thomas@schnuecker.de>
COPYRIGHT AND LICENSE
Copyright (C) 2004-2005 by Thomas Schnuecker
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
The data provided by weather.com and made accessible by this OO interface can be used for free under special terms. Please have a look at the application programming guide of weather.com (http://www.weather.com/services/xmloap.html)!