Masahiro Nagano > WebService-Livedoor-Weather-0.02 > WebService::Livedoor::Weather

Download:
WebService-Livedoor-Weather-0.02.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Module Version: 0.02   Source   Latest Release: WebService-Livedoor-Weather-0.10

NAME ^

WebService::Livedoor::Weather - Perl interface to Livedoor Weather Web Service

SYNOPSIS ^

  use WebService::Livedoor::Weather;

  $lwws = WebService::Livedoor::Weather->new;
  my $ret = $lwws->get('63','tomorrow'); #63 is tokyo

  print $ret->{title};
  print $ret->{description};

DESCRIPTION ^

WebService::Livedoor::Weather is a simple interface to Livedoor Weather Web Service (LWWS)

METHODS ^

new
    $lwws = WebService::Livedoor::Weather->new;
    $lwws = WebService::Livedoor::Weather->new(fetch=>{
        Cache=>$c
    });

creates an instance of WebService::Livedoor::Weather.

fetch is option for URI::Fetch that used for fetching weather information.

get(cityid or name,[day])
    my $ret = $lwws->get('63','tomorrow'); #63 is tokyo
    my $ret = $lwws->get('cityname','today');

retrieve weather. You can get a city id from http://weather.livedoor.com/forecast/rss/forecastmap.xml

SEE ALSO ^

URI::Fetch http://weather.livedoor.com/weather_hacks/webservice.html (Japanese)

AUTHOR ^

Masahiro Nagano, <kazeburo@nomadscafe.jp>

COPYRIGHT AND LICENSE ^

Copyright (C) 2006 by Masahiro Nagano

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.5 or, at your option, any later version of Perl 5 you may have available.

syntax highlighting: