pub trait INSDate: PNSObject {
Show 17 methods
// Provided methods
fn m_date() -> Self
where Self: Sized + FromId { ... }
fn m_date_with_time_interval_since_now(
time_interval: NSTimeInterval,
) -> Self
where Self: Sized + FromId { ... }
fn m_date_with_time_interval_since_date(
secs_to_be_added: NSTimeInterval,
date: NSDate,
) -> Self
where Self: Sized + FromId { ... }
fn m_date_with_time_interval_since_reference_date(
secs_to_be_added: NSTimeInterval,
) -> Self
where Self: Sized + FromId { ... }
fn m_date_with_time_interval_since1970(
secs_to_be_added: NSTimeInterval,
) -> Self
where Self: Sized + FromId { ... }
fn p_distant_future() -> NSDate { ... }
fn p_distant_past() -> NSDate { ... }
fn p_now() -> NSDate { ... }
fn m_is_equal_to_date(&self, date: NSDate) -> bool { ... }
fn m_earlier_date(&self, date: NSDate) -> Self
where Self: Sized + FromId { ... }
fn m_later_date(&self, date: NSDate) -> Self
where Self: Sized + FromId { ... }
fn m_compare(&self, date: NSDate) -> NSComparisonResult { ... }
fn m_time_interval_since_date(&self, date: NSDate) -> NSTimeInterval { ... }
fn p_time_interval_since_now(&self) -> NSTimeInterval { ... }
fn p_time_interval_since_reference_date() -> NSTimeInterval { ... }
fn p_time_interval_since_1970() -> NSTimeInterval { ... }
fn m_date_by_adding_time_interval(
&self,
secs_to_be_added: NSTimeInterval,
) -> Self
where Self: Sized + FromId { ... }
}Expand description
A trait containing all the methods for NSDate
Provided Methods§
Sourcefn m_date_with_time_interval_since_now(time_interval: NSTimeInterval) -> Self
fn m_date_with_time_interval_since_now(time_interval: NSTimeInterval) -> Self
Creates and returns a date object set to a given number of seconds from the current date and time.
Sourcefn m_date_with_time_interval_since_date(
secs_to_be_added: NSTimeInterval,
date: NSDate,
) -> Self
fn m_date_with_time_interval_since_date( secs_to_be_added: NSTimeInterval, date: NSDate, ) -> Self
Creates and returns a date object set to a given number of seconds from the specified date.
Sourcefn m_date_with_time_interval_since_reference_date(
secs_to_be_added: NSTimeInterval,
) -> Self
fn m_date_with_time_interval_since_reference_date( secs_to_be_added: NSTimeInterval, ) -> Self
Creates and returns a date object set to a given number of seconds from 00:00:00 UTC on 1 January 2001.
Sourcefn m_date_with_time_interval_since1970(secs_to_be_added: NSTimeInterval) -> Self
fn m_date_with_time_interval_since1970(secs_to_be_added: NSTimeInterval) -> Self
Creates and returns a date object set to the given number of seconds from 00:00:00 UTC on 1 January 1970.
Sourcefn p_distant_future() -> NSDate
fn p_distant_future() -> NSDate
A date object representing a date in the distant future.
Sourcefn p_distant_past() -> NSDate
fn p_distant_past() -> NSDate
A date object representing a date in the distant past.
Sourcefn m_is_equal_to_date(&self, date: NSDate) -> bool
fn m_is_equal_to_date(&self, date: NSDate) -> bool
Returns a Boolean value that indicates whether a given object is a date that is exactly equal the receiver.
Sourcefn m_earlier_date(&self, date: NSDate) -> Self
fn m_earlier_date(&self, date: NSDate) -> Self
Returns the earlier of the receiver and another given date.
Sourcefn m_later_date(&self, date: NSDate) -> Self
fn m_later_date(&self, date: NSDate) -> Self
Returns the later of the receiver and another given date.
Sourcefn m_compare(&self, date: NSDate) -> NSComparisonResult
fn m_compare(&self, date: NSDate) -> NSComparisonResult
Indicates the temporal ordering of the receiver and another given date.
Sourcefn m_time_interval_since_date(&self, date: NSDate) -> NSTimeInterval
fn m_time_interval_since_date(&self, date: NSDate) -> NSTimeInterval
Returns the interval between the receiver and another given date.
Sourcefn p_time_interval_since_now(&self) -> NSTimeInterval
fn p_time_interval_since_now(&self) -> NSTimeInterval
The interval between the date object and the current date and time.
Sourcefn p_time_interval_since_reference_date() -> NSTimeInterval
fn p_time_interval_since_reference_date() -> NSTimeInterval
The interval between the date object and 00:00:00 UTC on 1 January 2001.
Sourcefn p_time_interval_since_1970() -> NSTimeInterval
fn p_time_interval_since_1970() -> NSTimeInterval
The interval between the date object and 00:00:00 UTC on 1 January 1970.
Sourcefn m_date_by_adding_time_interval(
&self,
secs_to_be_added: NSTimeInterval,
) -> Self
fn m_date_by_adding_time_interval( &self, secs_to_be_added: NSTimeInterval, ) -> Self
Returns a new date object that is set to a given number of seconds relative to the receiver.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.