Contents

init(countdownDuration:schedule:attributes:stopIntent:secondaryIntent:sound:)

Creates a configuration that behaves like a countdown.

Declaration

init(countdownDuration: Alarm.CountdownDuration? = nil, schedule: Alarm.Schedule? = nil, attributes: AlarmAttributes<Metadata>, stopIntent: (any LiveActivityIntent)? = nil, secondaryIntent: (any LiveActivityIntent)? = nil, sound: AlertConfiguration.AlertSound = .default)

Parameters

  • countdownDuration:

    The optional countdown duration. When set to a non-nil value, a countdown shows in the Lock Screen for the specified duration.

  • schedule:

    The schedule that determines when the alarm alerts.

  • attributes:

    The attributes of the alarm.

  • stopIntent:

    The intent to execute when a person stops the countdown.

  • secondaryIntent:

    The intent to execute when a person taps the secondary button.

  • sound:

    The sound to play when the alarm fires.

See Also

Configuring a countdown