Structure_Concurrency5.9.0
Instant
- iOS
- 16.0+
- macOS
- 13.0+
- tvOS
- 16.0+
- watchOS
- 9.0+
struct Instant
Citizens in _Concurrency
Conformances
protocol Comparable
A type that can be compared using the relational operators
<
,<=
,>=
, and>
.protocol Decodable
A type that can decode itself from an external representation.
protocol Encodable
A type that can encode itself to an external representation.
protocol Equatable
A type that can be compared for value equality.
protocol Hashable
A type that can be hashed into a
Hasher
to produce an integer hash value.protocol InstantProtocol
protocol Sendable
A type whose values can safely be passed across concurrency domains by copying.
Members
init(from: Decoder
) throws static var now: SuspendingClock.Instant
static func + (SuspendingClock
.Instant, Duration) -> SuspendingClock.Instant static func += (inout SuspendingClock
.Instant, Duration) static func - (SuspendingClock
.Instant, Duration) -> SuspendingClock.Instant static func - (SuspendingClock
.Instant, SuspendingClock.Instant) -> Duration static func -= (inout SuspendingClock
.Instant, Duration) static func < (SuspendingClock
.Instant, SuspendingClock.Instant) -> Bool static func == (SuspendingClock
.Instant, SuspendingClock.Instant) -> Bool func advanced(by: Duration
) -> SuspendingClock.Instant func duration(to: SuspendingClock.Instant
) -> Duration func hash(into: inout Hasher
)
Features
static func != (Self, Self
) -> Bool 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.