nwsxml.pl File Reference

Go to the source code of this file.

Functions

 our ($opt_v, $opt_t, $opt_T, $opt_l, $opt_u, $opt_d)
 getopts ('Tvtlu:d:')
 if (defined $opt_v)
 if (!(defined $opt_u &&defined $loc &&!$loc eq""))
 foreach (@types)

Variables

use strict
use NWSLocation
my $name = 'NWS-XML'
my $version = 0.2
my $author = 'Lucien Dunning'
my $email = 'ldunning@gmail.com'
my $updateTimeout = 15*60
my $retrieveTimeout = 30
my types
my $dir = "./"
my $loc = shift
my $units = $opt_u
my $base_url
die unless defined $response
my $xml = XMLin($response)


Function Documentation

our ( opt_v,
opt_t,
opt_T,
opt_l,
opt_u,
opt_d 
)

getopts ( 'Tvtlu:d:'   ) 

if ( defined $  opt_v  ) 

Definition at line 29 of file nwsxml.pl.

if ( defined $opt_u &&defined $loc &&!$loc eq""  ) 

Definition at line 68 of file nwsxml.pl.

foreach ( types  ) 

Definition at line 80 of file nwsxml.pl.


Variable Documentation

use strict

Definition at line 3 of file nwsxml.pl.

Definition at line 8 of file nwsxml.pl.

my $name = 'NWS-XML'

Definition at line 12 of file nwsxml.pl.

my $version = 0.2

Definition at line 13 of file nwsxml.pl.

my $author = 'Lucien Dunning'

Definition at line 14 of file nwsxml.pl.

my $email = 'ldunning@gmail.com'

Definition at line 15 of file nwsxml.pl.

my $updateTimeout = 15*60

Definition at line 16 of file nwsxml.pl.

my $retrieveTimeout = 30

Definition at line 17 of file nwsxml.pl.

my types

Initial value:

 ('cclocation', 'station_id', 'latitude', 'longitude',
        'observation_time', 'observation_time_rfc822', 'weather',
        'temperature_string', 'temp', 'relative_humidity', 'wind_string',
        'wind_dir', 'wind_degrees', 'wind_speed', 'wind_gust',
        'pressure_string', 'pressure', 'dewpoint_string', 'dewpoint',
        'heat_index_string', 'heat_index', 'windchill_string', 'windchill',
        'visibility', 'weather_icon', 'appt', 'wind_spdgst')

Definition at line 18 of file nwsxml.pl.

my $dir = "./"

Definition at line 25 of file nwsxml.pl.

my $loc = shift

Definition at line 67 of file nwsxml.pl.

my $units = $opt_u

Definition at line 72 of file nwsxml.pl.

my $base_url

Initial value:

 'http:

my $response = get $base_url . $loc . '.xml'

Definition at line 74 of file nwsxml.pl.

die unless defined $response

Definition at line 77 of file nwsxml.pl.

my $xml = XMLin($response)

Definition at line 79 of file nwsxml.pl.


Generated on Sat Dec 18 05:15:54 2010 for MythTV by  doxygen 1.5.5