Contents

seconds(_:)

Construct a Duration given a number of seconds represented as a Double by converting the value into the closest attosecond scale value.

Declaration

static func seconds(_ seconds: Double) -> Duration

Return Value

A Duration representing a given number of seconds.

Discussion

  let d: Duration = .seconds(22.93)

See Also

Creating a duration