Weather::Com::Location(3) class representing one location and its weather

METHODS


id()

Returns the location id used to instantiate this location.

name()

Returns the name of the location as provided by weather.com.

current_conditions()

Returns a Weather::Com::CurrentConditions object containing the current conditions of the location.

The Weather::Com::CurrentConditions object is instantiated with the first call of the "current_conditions()" method.

Please refer to Weather::Com::CurrentConditions for further details.

forecast()

Returns a Weather::Com::Forecast object.

Please refer to Weather::Com::Forecast for further details.

latitude()

Returns the latitude of the location.

longitude()

Returns the longitude of the location.

localtime()

Returns a Weather::Com::DateTime object containing the local time of the location.

This value is evaluated each time you call this method. We do not use the value returned from weather.com here because it does not make any sence to use a cached value to show the current time.

localtime_ampm()

This method is deprecated and will be removed with the next release!

Returns the local time of the location.

The time is returned in the format "hh:mm [AM|PM]". To get a 24 hour format use "localtime" instead.

  Sample: 10:30 PM

sunrise()

Returns a Weather::Com::DateTime object containing the time of sunrise.

sunrise_ampm()

This method is deprecated and will be removed with the next release!

Returns the time of sunrise in 12 hour format (see "localtime_ampm()" for details).

sunset()

Returns a Weather::Com::DateTime object containing the time of sunset.

sunset_ampm()

This method is deprecated and will be removed with the next release!

Returns the time of sunset in 12 hour format (see "localtime_ampm()" for details).

timezone()

Returns the timezone offset to GMT (without respecting daylight savings time).

units()

Returns a Weather::Com::Units object.

Please refer to Weather::Com::Units for further details.