Struct Timespec

pub struct Timespec {
    sec: i64,
    nsec: i32,
}

A record specifying a time value in seconds and nanoseconds.

Struct Tm

pub struct Tm {
    tm_sec: i32,
    tm_min: i32,
    tm_hour: i32,
    tm_mday: i32,
    tm_mon: i32,
    tm_year: i32,
    tm_wday: i32,
    tm_yday: i32,
    tm_isdst: i32,
    tm_gmtoff: i32,
    tm_zone: ~str,
    tm_nsec: i32,
}

Implementation of ::std::cmp::Eq for Timespec

Automatically derived.

Method eq

fn eq(&self, __arg_0: &Timespec) -> ::bool

Method ne

fn ne(&self, __arg_0: &Timespec) -> ::bool

Implementation of ::extra::serialize::Encodable<__E> for Timespec where <__E: ::extra::serialize::Encoder>

Automatically derived.

Method encode

fn encode(&self, __arg_0: &mut __E)

Implementation of ::extra::serialize::Decodable<__D> for Timespec where <__D: ::extra::serialize::Decoder>

Automatically derived.

Method decode

fn decode(__arg_0: &mut __D) -> Timespec

Implementation for Timespec

Method new

fn new(sec: i64, nsec: i32) -> Timespec

Implementation of Ord for Timespec

Method lt

fn lt(&self, other: &Timespec) -> bool

Method le

fn le(&self, other: &Timespec) -> bool

Method ge

fn ge(&self, other: &Timespec) -> bool

Method gt

fn gt(&self, other: &Timespec) -> bool

Implementation of ::std::cmp::Eq for Tm

Automatically derived.

Method eq

fn eq(&self, __arg_0: &Tm) -> ::bool

Method ne

fn ne(&self, __arg_0: &Tm) -> ::bool

Implementation of ::extra::serialize::Encodable<__E> for Tm where <__E: ::extra::serialize::Encoder>

Automatically derived.

Method encode

fn encode(&self, __arg_0: &mut __E)

Implementation of ::extra::serialize::Decodable<__D> for Tm where <__D: ::extra::serialize::Decoder>

Automatically derived.

Method decode

fn decode(__arg_0: &mut __D) -> Tm

Implementation for Tm

Method to_timespec

fn to_timespec(&self) -> Timespec

Convert time to the seconds from January 1, 1970

Method to_local

fn to_local(&self) -> Tm

Convert time to the local timezone

Method to_utc

fn to_utc(&self) -> Tm

Convert time to the UTC

Method ctime

fn ctime(&self) -> ~str

Return a string of the current time in the form "Thu Jan 1 00:00:00 1970".

Method strftime

fn strftime(&self, format: &str) -> ~str

Formats the time according to the format string.

Method rfc822

fn rfc822(&self) -> ~str

Returns a time string formatted according to RFC 822.

local: "Thu, 22 Mar 2012 07:53:18 PST" utc: "Thu, 22 Mar 2012 14:53:18 UTC"

Method rfc822z

fn rfc822z(&self) -> ~str

Returns a time string formatted according to RFC 822 with Zulu time.

local: "Thu, 22 Mar 2012 07:53:18 -0700" utc: "Thu, 22 Mar 2012 14:53:18 -0000"

Method rfc3339

fn rfc3339(&self) -> ~str

Returns a time string formatted according to ISO 8601.

local: "2012-02-22T07:53:18-07:00" utc: "2012-02-22T14:53:18Z"

Function at

fn at(clock: Timespec) -> Tm

Returns the specified time in the local timezone

Function at_utc

fn at_utc(clock: Timespec) -> Tm

Returns the specified time in UTC

Function empty_tm

fn empty_tm() -> Tm

Function get_time

fn get_time() -> Timespec

Returns the current time as a timespec containing the seconds and nanoseconds since 1970-01-01T00:00:00Z.

Function now

fn now() -> Tm

Returns the current time in the local timezone

Function now_utc

fn now_utc() -> Tm

Returns the current time in UTC

Function precise_time_ns

fn precise_time_ns() -> u64

Returns the current value of a high-resolution performance counter in nanoseconds since an unspecified epoch.

Function precise_time_s

fn precise_time_s() -> float

Returns the current value of a high-resolution performance counter in seconds since an unspecified epoch.

Function strftime

fn strftime(format: &str, tm: &Tm) -> ~str

Formats the time according to the format string.

Function strptime

fn strptime(s: &str, format: &str) -> Result<Tm, ~str>

Parses the time from the string according to the format string.

Function tzset

fn tzset()