TimeAmount
Represents a time interval.
struct TimeAmount
Represents a time interval.
struct TimeAmount
static var zero: TimeAmount
The zero value for TimeAmount
.
let nanoseconds: Int64
The nanoseconds representation of the TimeAmount
.
static func hours(Int64) -> TimeAmount
Creates a new TimeAmount
for the given amount of hours.
static func microseconds(Int64) -> TimeAmount
Creates a new TimeAmount
for the given amount of microseconds.
static func milliseconds(Int64) -> TimeAmount
Creates a new TimeAmount
for the given amount of milliseconds.
static func minutes(Int64) -> TimeAmount
Creates a new TimeAmount
for the given amount of minutes.
static func nanoseconds(Int64) -> TimeAmount
Creates a new TimeAmount
for the given amount of nanoseconds.
static func seconds(Int64) -> TimeAmount
Creates a new TimeAmount
for the given amount of seconds.
static func + (Self) -> Self
Returns the given number unchanged.
static func += (inout Self, Self)
Adds two values and stores the result in the left-hand-side variable.
static func -= (inout Self, Self)
Subtracts the second value from the first and stores the difference in the left-hand-side variable.
static func ... (Self) -> PartialRangeFrom<Self>
Returns a partial range extending upward from a lower bound.
static func ... (Self) -> PartialRangeThrough<Self>
Returns a partial range up to, and including, its upper bound.
static func ... (Self, Self) -> ClosedRange<Self>
Returns a closed range that contains both of its bounds.
static func ..< (Self) -> PartialRangeUpTo<Self>
Returns a partial range up to, but not including, its upper bound.
static func ..< (Self, Self) -> Range<Self>
Returns a half-open range that contains its lower bound but not its upper bound.
static func <= (Self, Self) -> Bool
Returns a Boolean value indicating whether the value of the first argument is less than or equal to that of the second argument.
static func > (Self, Self) -> Bool
Returns a Boolean value indicating whether the value of the first argument is greater than that of the second argument.
static func >= (Self, Self) -> Bool
Returns a Boolean value indicating whether the value of the first argument is greater than or equal to that of the second argument.
static func != (Self, Self) -> Bool
static func * <T>(TimeAmount, T) -> TimeAmount
static func * <T>(T, TimeAmount) -> TimeAmount
static func + (TimeAmount, TimeAmount) -> TimeAmount
Adds two values and produces their sum.
static func += (inout TimeAmount, TimeAmount)
Adds two values and stores the result in the left-hand-side variable.
static func - (TimeAmount, TimeAmount) -> TimeAmount
Subtracts one value from another and produces their difference.
static func -= (inout TimeAmount, TimeAmount)
Subtracts the second value from the first and stores the difference in the left-hand-side variable.
static func < (TimeAmount, TimeAmount) -> Bool
Returns a Boolean value indicating whether the value of the first argument is less than that of the second argument.
typealias Value
Deprecated