AI-generated Key Takeaways
- 
          All methods in UMPConsentInformation must be called on the main thread. 
- 
          Use the sharedInstanceto access the shared consent information instance.
- 
          The user's consent status is available through consentStatus.
- 
          canRequestAdsindicates if the SDK has gathered consent for requesting ads.
- 
          Call requestConsentInfoUpdateWithParameters:completionHandler:in every app session to update consent information before checking status or loading forms.
UMPConsentInformation
@interface UMPConsentInformation : NSObjectConsent information. All methods must be called on the main thread.
- 
                  
                  The shared consent information instance. DeclarationSwift class var shared: ConsentInformation { get }Objective-C @property (class, nonatomic, readonly, nonnull) UMPConsentInformation *sharedInstance;
- 
                  
                  The user’s consent status. This value defaults to UMPConsentStatusUnknown until requestConsentInfoUpdateWithParameters:completionHandler: is called, and defaults to the previous session’s value until |completionHandler| from requestConsentInfoUpdateWithParameters:completionHandler: is called. DeclarationSwift var consentStatus: ConsentStatus { get }Objective-C @property (nonatomic, readonly) UMPConsentStatus consentStatus;
- 
                  
                  Indicates whether the SDK has gathered consent aligned with the app’s configured messages. Returns NO until requestConsentInfoUpdateWithParameters:completionHandler: is called. DeclarationSwift var canRequestAds: Bool { get }Objective-C @property (nonatomic, readonly) BOOL canRequestAds;
- 
                  
                  Consent form status. This value defaults to UMPFormStatusUnknown and requires a call to requestConsentInfoUpdateWithParameters:completionHandler: to update. DeclarationSwift var formStatus: FormStatus { get }Objective-C @property (nonatomic, readonly) UMPFormStatus formStatus;
- 
                  
                  Privacy options requirement status. This value defaults to UMPPrivacyOptionsRequirementStatusUnknown until requestConsentInfoUpdateWithParameters:completionHandler: is called, and defaults to the previous session’s value until |completionHandler| from requestConsentInfoUpdateWithParameters:completionHandler: is called. DeclarationSwift var privacyOptionsRequirementStatus: PrivacyOptionsRequirementStatus { get }Objective-C @property (nonatomic, readonly) UMPPrivacyOptionsRequirementStatus privacyOptionsRequirementStatus;
- 
                  
                  Requests consent information update. Must be called in every app session before checking the user’s consentStatus or loading a consent form. After calling this method, consentStatus will be updated synchronously to hold the consent state from the previous app session, if one exists. consentStatus may be updated again immediately before the completion handler is called. DeclarationSwift func requestConsentInfoUpdate(with parameters: RequestParameters?) async throwsObjective-C - (void) requestConsentInfoUpdateWithParameters: (nullable UMPRequestParameters *)parameters completionHandler: (nonnull UMPConsentInformationUpdateCompletionHandler) handler;
- 
                  
                  Clears all consent state from persistent storage. DeclarationSwift func reset()Objective-C - (void)reset;