ORKConsentSection Class Reference
| Inherits from | NSObject |
|---|---|
| Conforms to | NSCopying NSSecureCoding |
| Declared in | ORKConsentSection.h ORKConsentSection.m |
Overview
The ORKConsentSection class represents one section in a consent document. Each
ORKConsentSection object (apart from those of type ORKConsentSectionTypeOnlyInDocument)
corresponds to a page in a visual consent step, or a section in the document
reviewed in consent review step.
If you initialize a consent section with one of the defined section types, you get a prepopulated title, a default image, and animation (when appropriate). You can override these properties or you can use the ORKConsentSectionTypeCustom type to
avoid any prepopulation.
If you provide content for the ORKConsentSection object, be sure to use localized content.
– initWithType:
Returns an initialized consent section using the specified type.
- (instancetype)initWithType:(ORKConsentSectionType)typeParameters
type |
The consent section type. |
|---|
Discussion
This method populates the title and summary for all types except for
ORKConsentSectionTypeCustom and ORKConsentSectionTypeOnlyInDocument.
Declared In
ORKConsentSection.h
title
The title of the consent section in a localized string.
@property (nonatomic, copy, nullable) NSString *titleDiscussion
The title is displayed as a scene title in the animated consent sequence and is also included in the PDF file, but it can be overridden by setting formalTitle.
The title is prefilled unless the type is ORKConsentSectionTypeCustom or ORKConsentSectionTypeOnlyInDocument.
Declared In
ORKConsentSection.h
summary
A short summary of the content in a localized string.
@property (nonatomic, copy, nullable) NSString *summaryDiscussion
The summary is displayed as description text in the animated consent sequence. The summary should be limited in length, so that the consent can be reliably displayed on smaller screens.
Declared In
ORKConsentSection.h
content
The content of the section in a localized string.
@property (nonatomic, copy, nullable) NSString *contentDiscussion
In a consent review step or in PDF file generation, the string is printed as the section’s content. The string is also displayed as Learn More content in a visual consent step.
This property is never prepopulated based on the value of type. If both content and htmlContent are non-nil, the value of the htmlContent property is used.
Declared In
ORKConsentSection.h
htmlContent
The HTML content used to override the content property if additional formatting is needed. The content should be localized.
@property (nonatomic, copy, nullable) NSString *htmlContentDiscussion
In cases where plain text content is not sufficient to convey important details
during the consent process, you can provide HTML content in this property. When you do this, the htmlContent property takes precedence over the content property.
In a consent review step or in PDF file generation, the value of this property is printed as the section’s content; in a visual consent step, the content is displayed as Learn More content.
Declared In
ORKConsentSection.h
contentURL
The NSURL used to override the ‘htmlContent’ and ‘consent’ property if a document should be required.
@property (nonatomic, copy, nullable) NSURL *contentURLDiscussion
This property is used to display a document when required by an authortity.
Declared In
ORKConsentSection.h
omitFromDocument
When set to YES, the section is omitted in a consent review step or in PDF file generation. This property is NO by default.
@property (nonatomic) BOOL omitFromDocumentDeclared In
ORKConsentSection.h
customImage
A custom illustration for the consent.
@property (nonatomic, copy, nullable) UIImage *customImageDiscussion
The custom image can override the image associated with any of the predefined
section types for an ORKVisualConsentStep object. It is ignored for a consent review step and
for PDF generation.
The image is used in template rendering mode, and is tinted using the tint color.
Declared In
ORKConsentSection.h
customLearnMoreButtonTitle
A custom Learn More button title in a localized string.
@property (nonatomic, copy, nullable) NSString *customLearnMoreButtonTitleDiscussion
The predefined section types have localized descriptive Learn More button
titles for a visual consent step. When this property is not nil, it overrides that
default text.
Declared In
ORKConsentSection.h
customAnimationURL
A file URL that specifies a custom transition animation video.
@property (nonatomic, copy, nullable) NSURL *customAnimationURLDiscussion
Animations of the illustration between one screen and the next are provided
by default for transitions between consecutive section type codes. Custom
sections and out-of-order transitions may require custom animations.
The animation loaded from the file URL is played aspect fill in the illustration area for forward transitions only. The video is rendered in template mode, with white treated as if it were transparent.
Declared In
ORKConsentSection.h