Sidef::Time::Gmtime
Returned values are localized for the standard Greenwich time zone.
var time = Time.gmtime;
Inherits methods from:
* Sidef::Object::Object
Time.gmtime.ctime() -> String
Return the ctime(3) value:
Time.gmtime.ctime # e.g., "Thu Jul 18 17:39:28 2013"
Time.gmtime.day() -> Number
Aliases: mday().
Return the day of the month.
Time.gmtime.hour() -> Number
Return the hours of the specified time.
Time.gmtime.min() -> Number
Return the minutes of the specified time.
Time.gmtime.mon() -> Number
Aliases: month().
Return the month in the range 0..11, with 0 indicating January and 11 indicating December.
Time.gmtime.sec() -> Number
Return the seconds of the specified time.
Time.gmtime.strftime(String) -> String
Format the time with POSIX::strftime().
Time.gmtime.strftime("%a %b %e %H:%M:%S %Y") # e.g., "Thu Jul 18 17:27:50 2013"
For more details, see: man strftime
man strftime
Time.gmtime.wday() -> Number
Return the day of the week, with 0 indicating Sunday and 3 indicating Wednesday.
Time.gmtime.yday() -> Number
Return the day of the year, in the range 0..364 (or 0..365 in leap years.)
Time.gmtime.year() -> Number
Return the number of years since 1900.
To get a 4-digit year, write:
var year = (Time.gmtime.year + 1900);
To install Sidef, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Sidef
CPAN shell
perl -MCPAN -e shell install Sidef
For more information on module installation, please visit the detailed CPAN module installation guide.