10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Good Day
Kindly assist:
I am creating an Alert that will notify supervisors of staff members who are due for probation report. I am using Operating System Script(Unix) as source.I have already developed the script.
Now the challenge is if there are 3 employee records then the alert... (2 Replies)
Discussion started by: nosi27
2 Replies
2. Shell Programming and Scripting
Can someone get me script to find swap space for linux servers (1 Reply)
Discussion started by: Moon1234
1 Replies
3. Red Hat
Hello All,
Nagios seems to be sending false alerts about few hosts, (ex: There were no users on one host and still Nagios was reporting a critical alert and says 6 users are logged in. How do I fix this one?
Also, I have installed nagios and added 12 hosts as a start and monitoring few... (4 Replies)
Discussion started by: lovesaikrishna
4 Replies
4. Solaris
How can I send messages to users who are logged in unto the server with Solaris 9 OS without going into the application? (3 Replies)
Discussion started by: rahmantanko
3 Replies
5. UNIX for Dummies Questions & Answers
Hi,
I need to know whether a port is being used by some application.
What is the command for the same??
Regards,
Chaitrali. (1 Reply)
Discussion started by: Chaitrali
1 Replies
6. UNIX for Advanced & Expert Users
Hi experts,
I am using Linux 2.6.9.
My requirement is I want to send a message to the phone once my scheduled backup is complete. I don't know whether it's possible or not but I heard it can be done but don't know how.
Can comebody help me on this?
Thanks in advance.
Gary (1 Reply)
Discussion started by: abcabc1103
1 Replies
7. Shell Programming and Scripting
Hi,
My local server is :/usr/abcd/
Remote server is :/Usr/host/test/
I want to send files from local unix directory(All files starting with O_999) to
remote host unix directory.
Can any body give me the Unix Shell script to do this.
One more doubt: Shall we need to change the file... (1 Reply)
Discussion started by: raja_1234
1 Replies
8. Cybersecurity
Hi everyone,
Does anyone use a good unix security alert provider (such as CERT/SANS) that caters specifically to Unix and would provide a similar method of alert reporting? Any suggestions (with links!! :) ) would be helpful and appreciated.
Thanks in advance
:p (4 Replies)
Discussion started by: cbalemba
4 Replies
9. UNIX for Dummies Questions & Answers
I want to know if there is a way to send unix commands thru FTP from a mainframe to kick off Autosys Jobs. I just need to send a command from the mainframe to UNIX and have UNIX execute that command. (2 Replies)
Discussion started by: skammer
2 Replies
10. UNIX for Dummies Questions & Answers
whats the cmd to send messages using terminal to another computer on our network?
We are running SOlaris CDE (5 Replies)
Discussion started by: korupt
5 Replies
Weather::Com::Location(3pm) User Contributed Perl Documentation Weather::Com::Location(3pm)
NAME
Weather::Com::Location - class representing one location and its weather
SYNOPSIS
#!/usr/bin/perl -w
use Weather::Com::Finder;
# you have to fill in your ids from weather.com here
my $PartnerId = 'somepartnerid';
my $LicenseKey = 'mylicense';
my %weatherargs = (
'partner_id' => $PartnerId,
'license' => $LicenseKey,
);
my $finder = Weather::Com::Finder->new(%weatherargs);
# if you want an array of locations:
my @locations = $finder->find('Heidelberg');
# or if you prefer an arrayref:
my $locations = $finder->find('Heidelberg');
foreach my $location (@locations) {
print "Found weather for city: ", $location->name(), "
";
print "The city is located at: ", $location->latitude(), "deg N, ",
$location->longitude(), "deg E
";
print "Local time is ", $location->localtime()->time(), "
";
print "Sunrise will be/has been at ", $location->sunrise()->time(), "
";
}
DESCRIPTION
Using Weather::Com::Location objects is the way to access weather (and some location) information for one specific location (city).
You get Weather::Com::Location objects by using a finder object (see Weather::Com::Finder).
Weather::Com::Location is a subclass of Weather::Com::Cached. An instance of this class will update itself corresponding to the caching
rules any time one of its methods is called.
CONSTRUCTOR
new(hash or hashref)
The constructor will usually not be used directly because you get ready to use location objects by using a finder.
If you ever want to instantiate location objects on your own, you have to provide the same configuration hash or hashref to the constructor
you usually would provide to the "new()" method of Weather::Com::Finder. In addition it is necessary to add a hash element "location_id"
to this config hash. The "location_id" has to be a valid weather.com location id.
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.
SEE ALSO
See also documentation of Weather::Com, Weather::Com::CurrentConditions, Weather::Com::Units.
AUTHOR
Thomas Schnuecker, <thomas@schnuecker.de>
COPYRIGHT AND LICENSE
Copyright (C) 2004-2007 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)
perl v5.8.8 2007-07-09 Weather::Com::Location(3pm)