ORKQuestionResult Class Reference
Inherits from | ORKResult : NSObject |
---|---|
Declared in | ORKQuestionResult.h ORKQuestionResult.m |
Overview
The ORKQuestionResult
class is the base class for leaf results from an item that uses an answer format (ORKAnswerFormat
).
A question result is typically generated by the framework as the task proceeds. When the task completes, it may be appropriate to serialize it for transmission to a server, or to immediately perform analysis on it.
See also: ORKQuestionStep
and ORKFormItem
.
Other Methods
– isSaveable
A boolean value indicating whether this result can be saved in a save and restore procedure.
- (BOOL)isSaveable
Discussion
This is currently considered a private method, but overriding the getter in a result is the correct way to prevent this result being considered as saveable for the purpose of deciding whether to offer a “Save” option when the user cancels a task in progress.
ORKResult
subclasses should return YES if they have data that the user
might want to be able to restore if the task were interrupted and later
resumed from the current state.
Declared In
ORKResult_Private.h
Other Methods
questionType
A value that indicates the type of question the result came from.
@property (nonatomic) ORKQuestionType questionType
Discussion
The value of questionType
generally correlates closely with the class, but it can be
easier to use this value in a switch statement in Objective-C.
Declared In
ORKQuestionResult.h