Structures
The following structures are available globally.
-
See moreCodingKeyfor converting a decoding container to a dictionary where any key in the dictionary is accessible.Declaration
Swift
public struct AnyCodingKey : CodingKey -
Wrapper for any codable array.
See moreDeclaration
Swift
public struct AnyCodableArray : Codable -
Wrapper for any codable dictionary.
See moreDeclaration
Swift
public struct AnyCodableDictionary : Codable
-
RSDActiveUIStepCommandis anOptionSetfor certain commonly used commands that are used at the beginning and end of an active step.See moreSeealso
RSDActiveUIStepDeclaration
Swift
public struct RSDActiveUIStepCommand : RSDStringLiteralOptionSet
-
See moreRSDAnswerResultObjectis a concrete implementation of a result that can be described using a single value.Declaration
Swift
public struct RSDAnswerResultObject : RSDAnswerResult, Codable
-
See moreRSDAnswerResultTypeis aCodablestruct that can be used to describe how to encode and decode anRSDAnswerResult. It carries information about the type of the value and how to encode it. This struct serves a different purpose from theRSDFormDataTypebecause it only carries information required to store a result and not additional information about presentation style.Declaration
Swift
public struct RSDAnswerResultType : Codable, Hashable, Equatable
-
The type of the async action configuration. This is used to decode async action configurations using an instance of
RSDFactory.See moreSeealso
RSDAsyncActionConfigurationDeclaration
Swift
public struct RSDAsyncActionType : RSDFactoryTypeRepresentable, Codable, Hashable
-
See moreRSDChoiceObjectis a concrete implementation ofRSDChoicethat can be used to track a multiple choice, single choice, or multiple component input field where each choice in the input field maps to a specific value.Declaration
Swift
public struct RSDChoiceObject<T> : RSDChoice, RSDComparable, RSDEmbeddedIconVendor, Codable where T : Decodable, T : Encodable
-
A simple struct that can be used to implement the
See moreRSDChoiceOptionsprotocol.Declaration
Swift
public struct RSDChoiceOptionsObject : RSDChoiceOptions
-
Concrete implementation of the
See moreRSDCohortNavigationRule.Declaration
Swift
public struct RSDCohortNavigationRuleObject : RSDCohortNavigationRule, Codable
-
See moreRSDCollectionResultObjectis used include multiple results associated with a single step or async action that may have more that one result.Declaration
Swift
public struct RSDCollectionResultObject : RSDCollectionResult, RSDNavigationResult, Codable, RSDCopyWithIdentifier
-
RSDColorPlacementThemeElementObjecttells the UI what the background color and foreground color are for a given view as well as whether or not the foreground elements should uselight style
.The mapping is handled using a dictionary of color placements to the color style for that placement.
See moreDeclaration
Swift
public struct RSDColorPlacementThemeElementObject : RSDColorMappingThemeElement, RSDDecodableBundleInfo -
RSDSingleColorThemeElementObjecttells the UI what the background color and foreground color are for a given view as well as whether or not the foreground elements should uselight style
.The mapping is handled using a single style for the entire view.
See moreDeclaration
Swift
public struct RSDSingleColorThemeElementObject : RSDColorMappingThemeElement, RSDDecodableBundleInfo
-
The type of the color mapping theme element. This is used to decode a
See moreRSDColorMappingThemeElementusing aRSDFactory. It can also be used to customize the UI.Declaration
Swift
public struct RSDColorMappingThemeElementType : RSDFactoryTypeRepresentable, Codable, Equatable, Hashable
-
A color library is a versioned collection of color swatches.
See moreDeclaration
Swift
public struct RSDColorLibrary : Codable, Equatable, Hashable, Comparable
-
The color palette struct is used to describe the color palette for a given application. This is intended for applications that use the Sage Design System.
See moreDeclaration
Swift
public struct RSDColorPalette : Codable, Equatable, Hashable -
The color key is a model object that contains the information needed by the color design system to describe the colors associated with a given set of components.
See moreDeclaration
Swift
public struct RSDColorKey : Codable, Equatable, Hashable, RSDColorMapping
-
A color swatch refers to a series of color tiles within the same family.
See moreDeclaration
Swift
public struct RSDColorSwatch : Codable, Equatable, Hashable, RSDColorFamily -
A special-case color swatch for gray scale components.
See moreDeclaration
Swift
public struct RSDGrayScale : Codable, Equatable, Hashable, RSDColorFamily -
A color tile is a single color and whether or not that color uses light style.
See moreDeclaration
Swift
public struct RSDColorTile : Codable, Equatable, Hashable
-
See moreRSDComparableSurveyRuleObjectis a survey rule that matches an expected result to the answer and vends a skip identifier if the match is evaluated totrue.Declaration
Swift
public struct RSDComparableSurveyRuleObject<T> : RSDComparableSurveyRule, Codable where T : Decodable, T : Encodable
-
See moreRSDConditionalStepNavigatorObjectis a concrete implementation of theRSDConditionalStepNavigatorprotocol.Declaration
Swift
public struct RSDConditionalStepNavigatorObject : RSDConditionalStepNavigator, RSDCopyStepNavigator, Decodable
-
RSDDateCoderObjectprovides a concrete implementation of aRSDDateCoder. The date coder is used by theRSDDateRangeObjectto encode and decode theminDateandmaxDateproperties as well as to get which components of a date should be stored in the answer for a givenRSDInputField.This coder uses ISO 8601 format to determine which calendar components to request from the user and to store from the input result. The
See morecalendaris ISO8601 and theresultFormatteris determined from thecalendarComponentsusing the sharedRSDFactoryor the factory associated with the decoder if instantiated using aDecoder. The locale for the date formatters isen_US_POSIX
by default.Declaration
Swift
public struct RSDDateCoderObject : RSDDateCoder, RawRepresentable
-
A simple struct that can be used to implement the
See moreRSDDatePickerDataSourceprotocol.Declaration
Swift
public struct RSDDatePickerDataSourceObject : RSDDatePickerDataSource
-
See moreRSDDateRangeObjectis a concrete implementation of aRSDDateRangethat defines the range of values appropriate for adatedata type.Declaration
Swift
public struct RSDDateRangeObject : RSDDateRange, Codable
-
RSDDeviceTypedescribes various devices. It can be used by a task to vend different steps or async actions based upon what is supported by a given device type.See moreNote
This is not currently used and may be deprecated.Declaration
Swift
public struct RSDDeviceType : RSDFactoryTypeRepresentable, Codable, Hashable
-
The default configuration to use for a
RSDDistanceRecorder.- example:
See more// Example json for a codable configuration. let json = """ { "identifier": "foo", "type": "distance", "motionStepIdentifier": "run" "startStepIdentifier": "countdown", "stopStepIdentifier": "rest", } """.data(using: .utf8)! // our data in native (JSON) formatDeclaration
Swift
@available(iOS 10.0, *) public struct RSDDistanceRecorderConfiguration : RSDRecorderConfiguration, Codable
-
See moreRSDDurationPickerDataSourceObjectis a concrete implementation of aRSDMultipleComponentChoiceOptionsthat can be used to select a duration using duration units for each component of the duration.Declaration
Swift
public struct RSDDurationPickerDataSourceObject : RSDMultipleComponentPickerDataSource
-
See moreRSDDurationRangeObjectextends the properties of anRSDInputFieldfor a.durationdata type.Declaration
Swift
public struct RSDDurationRangeObject : RSDDurationRange, RSDRangeWithFormatter, Codable
-
See moreRSDErrorResultis a result that holds information about an error.Declaration
Swift
public struct RSDErrorResultObject : RSDErrorResult, Codable
-
A manifest for a given file that includes the filename, content type, and creation timestamp.
See moreDeclaration
Swift
public struct RSDFileManifest : Codable, Hashable, Equatable
-
See moreRSDFileResultObjectis a concrete implementation of a result that holds a pointer to a file url.Declaration
Swift
public struct RSDFileResultObject : RSDFileResult, Codable
-
The
See moreRSDFormUIHintenum is a key word that can be used to describe the preferred UI for a form input field. This is intended as ahint
that the designers and developers can use to indicate the preferred input style for an input field. Not all ui hints are applicable to all data types or devices, and therefore the ui hint may be ignored by the application displaying the input field to the user.Declaration
Swift
public struct RSDFormUIHint : RawRepresentable, Codable, Hashable
-
RSDGenericStepObjectis a step with key/value pairs decoded from a dictionary. This is the default step returned byRSDFactoryfor an unrecoginized type.This step is intended for use as a placeholder step for decoding a step that may be defined using a customized subtype or for replacing properties on an
See moreRSDMutableStep.Declaration
Swift
public struct RSDGenericStepObject : RSDGenericStep, Decodable
-
The icon info is a simple image holder that also contains a title and subtitle for the image.
See moreDeclaration
Swift
public struct RSDIconInfo : Codable
-
See moreRSDIdentifieris intended to allow a developer to define constants for the identifiers that are used to define the tasks, steps, input fields, and async actions associated with a given task or task group.Declaration
Swift
public struct RSDIdentifier : RawRepresentable, Codable, Hashable
-
A concrete implementation for a
See moreRSDImagePickerStep.Declaration
Swift
public struct RSDImagePickerStepObject : RSDImagePickerStep, Codable
-
A hint as to where the UI should place an image.
See moreDeclaration
Swift
public struct RSDImagePlacementType : RawRepresentable, Codable, Hashable, Equatable
-
The type of the image theme. This is used to decode a
See moreRSDImageThemeElementusing aRSDFactory. It can also be used to customize the UI.Declaration
Swift
public struct RSDImageThemeElementType : RSDFactoryTypeRepresentable, Codable, Equatable, Hashable
-
See moreRSDImageWrappervends an image. It does not handle image caching. If your app using a custom image caching, then you will need to use the shared delegate to implement this. The image wrapper is designed to allow coding of images using animageNameproperty as a key for accessing the image.Declaration
Swift
public struct RSDImageWrapper
-
See moreRSDFetchableImageThemeElementObjectis aCodableconcrete implementation ofRSDFetchableImageThemeElement.Declaration
Swift
public struct RSDFetchableImageThemeElementObject : RSDFetchableImageThemeElement, RSDDecodableBundleInfo, Codable -
See moreRSDAnimatedImageThemeElementObjectis aCodableconcrete implementation ofRSDAnimatedImageThemeElement.Declaration
Swift
public struct RSDAnimatedImageThemeElementObject : RSDAnimatedImageThemeElement, RSDDecodableBundleInfo, Codable
-
The default configuration to use for a
RSDMotionRecorder.- example:
See more// Example json for a codable configuration. let json = """ { "identifier": "foo", "type": "motion", "startStepIdentifier": "start", "stopStepIdentifier": "stop", "requiresBackgroundAudio": true, "recorderTypes": ["accelerometer", "gyro", "magnetometer"], "frequency": 50 } """.data(using: .utf8)! // our data in native (JSON) formatDeclaration
Swift
@available(iOS 10.0, *) public struct RSDMotionRecorderConfiguration : RSDRestartableRecorderConfiguration, Codable
-
A simple struct that can be used to implement the
See moreRSDMultipleComponentOptionsprotocol.Declaration
Swift
public struct RSDMultipleComponentOptionsObject : RSDMultipleComponentOptions
-
A simple struct that can be used to implement the
See moreRSDNumberPickerDataSourceprotocol.Declaration
Swift
public struct RSDNumberPickerDataSourceObject : RSDNumberPickerDataSource
-
See moreRSDNumberRangeObjectextends the properties of anRSDInputFieldfor adecimalorintegerdata type.Declaration
Swift
public struct RSDNumberRangeObject : RSDNumberRange, RSDRangeWithFormatter, Codable
-
The
See moreRSDRegExValidatorObjectis a concrete implementation of theRSDCodableRegExMatchValidatorthat can be used to create a regex validation of an input string using a regex pattern.Declaration
Swift
public struct RSDRegExValidatorObject : RSDCodableRegExMatchValidator
-
See moreRSDResourceTypeis an extendable struct for describing the type of a resource. By default, these values will map to the file extension.Declaration
Swift
public struct RSDResourceType : RawRepresentable, Equatable, Hashable, Codable
-
See moreRSDResultObjectis a concrete implementation of the base result associated with a task, step, or asynchronous action.Declaration
Swift
public struct RSDResultObject : RSDNavigationResult, Codable
-
See moreRSDResultTypeis an extendable string enum used byRSDFactoryto create the appropriate result type.Declaration
Swift
public struct RSDResultType : RSDFactoryTypeRepresentable, Codable, Hashable
-
See moreRSDRecordMarkeris a concrete implementation ofRSDSampleRecordthat can be used to mark the step transitions for a recording.Declaration
Swift
public struct RSDRecordMarker : RSDSampleRecord -
Implementation of the
See moreRSDStringSeparatedEncodingFormatprotocol that wraps a comma separated encodable.Declaration
Swift
public struct CSVEncodingFormat<K> : RSDStringSeparatedEncodingFormat where K : RSDDelimiterSeparatedEncodable
-
See moreRSDSchemaInfoObjectis a concrete implementation of theRSDSchemaInfoprotocol.Declaration
Swift
public struct RSDSchemaInfoObject : RSDSchemaInfo, Codable, Hashable
-
Default implementation for building a task scoring.
See moreDeclaration
Swift
public struct RSDDefaultScoreBuilder : RSDScoreBuilder
-
See moreRSDSectionStepObjectis used to define a logical subgrouping of steps such as a section in a longer survey or an active step that includes an instruction step, countdown step, and activity step.Declaration
Swift
public struct RSDSectionStepObject : RSDSectionStep, RSDConditionalStepNavigator, RSDStepValidator, RSDCopyStep, Decodable
-
See moreRSDStandardAsyncActionConfigurationis a concrete implementation ofRSDRecorderConfigurationthat can be used to decode an async configuration for a recorder.Declaration
Swift
public struct RSDStandardAsyncActionConfiguration : RSDRecorderConfiguration, Codable
-
The type of the step. This is used to decode the step using a
See moreRSDFactory. It can also be used to customize the UI.Declaration
Swift
public struct RSDStepNavigatorType : RSDFactoryTypeRepresentable, Codable, Hashable
-
See moreRSDStepTransformerObjectis used in decoding a step with replacement properties for some or all of the steps in a section that is defined using a different resource. The factory will convert this step into an appropriateRSDSectionStepfrom the decoded object.Declaration
Swift
public struct RSDStepTransformerObject : RSDStepTransformer, Decodable
-
The type of the step. This is used to decode the step using a
See moreRSDFactory. It can also be used to customize the UI.Declaration
Swift
public struct RSDStepType : RSDFactoryTypeRepresentable, Codable, Hashable
-
See moreRSDTaskGroupObjectis a concrete implementation of theRSDTaskGroupprotocol.Declaration
Swift
public struct RSDTaskGroupObject : RSDTaskGroup, RSDEmbeddedIconVendor, Decodable
-
See moreRSDTaskInfoStepObjectis a concrete implementation of theRSDTaskInfoStepprotocol.Declaration
Swift
public struct RSDTaskInfoStepObject : RSDTaskInfoStep
-
The metadata for a task result archive that can be zipped using the app developer’s choice of third-party archival tools.
See moreDeclaration
Swift
public struct RSDTaskMetadata : Codable
-
See moreRSDTaskResultObjectis a result associated with a task. This object includes a step history, task run UUID, schema identifier, and asynchronous results.Declaration
Swift
public struct RSDTaskResultObject : RSDTaskRunResult, Codable
-
See moreRSDTextFieldOptionsObjectdefines the options for a text field.Declaration
Swift
public struct RSDTextFieldOptionsObject : RSDTextFieldOptions, Codable
-
See moreRSDUIActionObjectis a concrete implementation ofRSDUIActionthat can be used to customize the title and image displayed for a given action of the UI.Declaration
Swift
public struct RSDUIActionObject : RSDEmbeddedResourceUIAction, Codable -
See moreRSDNavigationUIActionObjectimplements an action for navigating to another step in a task.Declaration
Swift
public struct RSDNavigationUIActionObject : RSDEmbeddedResourceUIAction, RSDNavigationUIAction, Codable -
See moreRSDReminderUIActionObjectimplements an action for setting up a local notification to remind the participant about doing a particular task later.Declaration
Swift
public struct RSDReminderUIActionObject : RSDEmbeddedResourceUIAction, RSDReminderUIAction, Codable -
See moreRSDWebViewUIActionObjectimplements an action that includes a pointer to a url that can display in a webview. The url can either be fully qualified or optionally point to an embedded resource.Declaration
Swift
public struct RSDWebViewUIActionObject : RSDEmbeddedResourceUIAction, RSDWebViewUIAction, Codable -
See moreRSDVideoViewUIActionObjectimplements an action that includes a pointer to a url that can display in aAVPlayerViewController. The url can either be fully qualified or optionally point to an embedded resource.Declaration
Swift
public struct RSDVideoViewUIActionObject : RSDEmbeddedResourceUIAction, RSDVideoViewUIAction, Codable
-
The type of the ui action. This is used to decode a
See moreRSDUIActionusing aRSDFactory. It can also be used to customize the UI.Declaration
Swift
public struct RSDUIActionObjectType : RSDFactoryTypeRepresentable, Codable, Hashable
-
The type of transition style to use for displaying a UI component.
See moreDeclaration
Swift
public struct RSDTransitionStyle : RawRepresentable, Codable, Hashable
-
See moreRSDUSHeightPickerDataSourceObjectis a custom height picker for use when theLocaleuses US Customary units (not metric system).Declaration
Swift
public struct RSDUSHeightPickerDataSourceObject : RSDUSMeasurementPickerDataSource -
See moreRSDUSInfantMassPickerDataSourceis a custom weight picker for use when theLocaleuses US Customary units (not metric system) and the mass is for an infant inlb, oz
.Declaration
Swift
public struct RSDUSInfantMassPickerDataSourceObject : RSDUSMeasurementPickerDataSource
-
See moreRSDUnitConverteris a static struct for defined unit converters for converting between US English (imperial) to metric units. This is used to allow for displaying a person’s height or weight in imperial units, while storing the value in standardized metric units.Declaration
Swift
public struct RSDUnitConverter
-
See moreRSDViewThemeElementObjecttells the UI where to find the view controller to use when instantiating theRSDStepController.Declaration
Swift
public struct RSDViewThemeElementObject : RSDViewThemeElement, RSDDecodableBundleInfo, Codable
-
A weekly schedule item is a light-weight codable struct that can be used to store and track events that happen at regularily scheduled intervals. This schedule assumes a ISO8601 7-day calendar.
- example:
Codableprotocol schema.let json = """ { "daysOfWeek": [1, 3, 5], "timeOfDay": "08:00" } """.data(using: .utf8)! // our data in native (JSON) format
Declaration
Swift
public struct RSDWeeklyScheduleObject : Codable, RSDSchedule - example:
View on GitHub
Structures Reference