ORKAudioStepViewController Class Reference

Inherits from ORKActiveStepViewController : ORKStepViewController : UIViewController
Declared in ORKAudioStepViewController.h
ORKAudioStepViewController.m

– initWithStep:

Returns a new step view controller for the specified step.

- (instancetype)initWithStep:(ORKStep *)step

Parameters

step

The step to be presented.

Return Value

A newly initialized step view controller.

Declared In

ORKStepViewController.h

– recordersDidChange

Tells the view controller that the set of recorders changed.

- (void)recordersDidChange

Discussion

This method is usually called by the active step view controller in response to start or resume.

Subclasses may override this method.

Declared In

ORKActiveStepViewController.h

– start

Starts the active step.

- (void)start

Discussion

Call this method to start the timer on the active step, if there is one, and to start any data recording.

When you start the step, recorders are instantiated based on their configurations and then started. All timers should start, and the UI should show users that the step is in progress.

This method does nothing if the step has already started.

Subclasses should super when overriding this method.

Declared In

ORKActiveStepViewController.h

– suspend

Suspends the active step.

- (void)suspend

Discussion

Call this method to suspend data recording and the step’s timer.

This method may called automatically when the app is suspended. The view controller can be configured not to suspend even if the app goes into the background (for more information, see suspendIfInactive).

Subclasses should call super when overriding this method.

Declared In

ORKActiveStepViewController.h

– resume

Resumes the active step.

- (void)resume

Discussion

Call this method when the step should be resumed. Calls to this method should be paired with previous calls to suspend.

This method may be called automatically when the app is resumed. The view controller can be configured not to suspend even if the app goes into the background (for more information, see suspendIfInactive).

When the step is resumed, the UI should resume at the point where the user left off, or, if that does not make sense for the particular step, to the most recent suitable point.

Subclasses should call super when overriding this method.

Declared In

ORKActiveStepViewController.h

– finish

Finishes the active step.

- (void)finish

Discussion

Call this method to finish the active step. If the active step is configured with a timer, this method is called automatically when the timer expires.

Finishing the active step stops all data recording and stops any timers. In steps that have the shouldContinueOnFinish property set, forward navigation to the next step may ensue.

This method does nothing if the step has already finished.

Subclasses should call super when overriding this method.

Declared In

ORKActiveStepViewController.h

– stepDidFinish

Tells the view controller that the active step has finished.

- (void)stepDidFinish

Discussion

This method is an override point for subclasses, called by the base class when the step has just finished.

The default implementation does nothing except in the case of steps that have countdown enabled. When countdown is enabled in a step, the view controller attempts to navigate automatically to the next step, if so configured.

Declared In

ORKActiveStepViewController.h