Skip to content

Commit b1f6b59

Browse files
committed
Update UMP reference docs (#1456)
* Updated some reference doc text. * Typo fix.
1 parent f561ecd commit b1f6b59

File tree

2 files changed

+27
-8
lines changed

2 files changed

+27
-8
lines changed

gma/src/include/firebase/gma/ump/consent_info.h

Lines changed: 26 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,16 @@ namespace internal {
3939
class ConsentInfoInternal;
4040
} // namespace internal
4141

42+
/// @brief Consent Information class for the User Messaging Platform SDK.
43+
///
44+
/// The User Messaging Platform (UMP) SDK is Google’s option to handle user
45+
/// privacy and consent in mobile apps.
46+
///
4247
/// This class contains all of the methods necessary for obtaining
4348
/// consent from the user.
4449
class ConsentInfo {
4550
public:
46-
/// Shut down the User Messaging Platform Consent SDK
51+
/// Shut down the User Messaging Platform Consent SDK.
4752
~ConsentInfo();
4853

4954
/// Initializes the User Messaging Platform Consent SDK.
@@ -109,6 +114,9 @@ class ConsentInfo {
109114
/// @return A pointer to the ConsentInfo instance. Each call to GetInstance()
110115
/// will return the same pointer; when you are finished using the SDK, you can
111116
/// delete the pointer, and the UMP SDK will shut down.
117+
///
118+
/// @note Once any overload of ConsentInfo::GetInstance has been called, you
119+
/// can use this method to obtain the same instance again.
112120
static ConsentInfo* GetInstance(InitResult* init_result_out = nullptr);
113121
#endif // !defined(__ANDROID__) || defined(DOXYGEN)
114122

@@ -119,10 +127,10 @@ class ConsentInfo {
119127

120128
/// Requests consent information update. Must be called in every app session
121129
/// before checking the user’s consent status or loading a consent form. After
122-
/// calling this method, GetConsentStatus() will be updated immediately to
123-
/// hold the consent state from the previous app session, if one
124-
/// exists. GetConsentStatus() may be updated again immediately before the
125-
/// returned future is completed.
130+
/// calling this method, GetConsentStatus() and CanRequestAds() will be
131+
/// updated immediately to hold the consent state from the previous app
132+
/// session, if one exists. GetConsentStatus() and CanRequestAds() may be
133+
/// updated again immediately before the returned future is completed.
126134
Future<void> RequestConsentInfoUpdate(const ConsentRequestParameters& params);
127135

128136
/// Get the Future from the most recent call to RequestConsentInfoUpdate().
@@ -144,7 +152,11 @@ class ConsentInfo {
144152
/// will be dismissed and the Future will be completed after the user selects
145153
/// an option.
146154
///
147-
/// GetConsentStatus() is updated when the returned Future is completed.
155+
/// GetConsentStatus() and CanRequestAds() are updated when the returned
156+
/// Future is completed.
157+
///
158+
/// @param[in] parent A FormParent, which is an Activity object on Android and
159+
/// a UIViewController object on iOS.
148160
///
149161
/// @note You must call LoadConsentForm() and wait for it to complete before
150162
/// calling this method.
@@ -160,7 +172,11 @@ class ConsentInfo {
160172
/// (and the form is dismissed), or if the form is not required. The Future
161173
/// will be completed with an error if the form fails to load or show.
162174
///
163-
/// GetConsentStatus() will be updated prior to the Future being completed.
175+
/// GetConsentStatus() and CanRequestAds() will be updated prior to the Future
176+
/// being completed.
177+
///
178+
/// @param[in] parent A FormParent, which is an Activity object on Android and
179+
/// a UIViewController object on iOS.
164180
Future<void> LoadAndShowConsentFormIfRequired(FormParent parent);
165181

166182
/// Get the Future from the most recent call to
@@ -184,6 +200,9 @@ class ConsentInfo {
184200
/// presented. The privacy options form is preloaded by the SDK automatically
185201
/// when a form becomes available. If no form has been preloaded, the SDK will
186202
/// try to load one asynchronously.
203+
///
204+
/// @param[in] parent A FormParent, which is an Activity object on Android and
205+
/// a UIViewController object on iOS.
187206
Future<void> ShowPrivacyOptionsForm(FormParent parent);
188207

189208
/// Get the Future from the most recent call to ShowPrivacyOptionsForm().

gma/src/include/firebase/gma/ump/types.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ enum ConsentDebugGeography {
4747
};
4848

4949
/// Debug settings for `ConsentInfo::RequestConsentInfoUpdate()`. These let you
50-
/// force a speific geographic location. Be sure to include debug device IDs to
50+
/// force a specific geographic location. Be sure to include debug device IDs to
5151
/// enable this on hardware. Debug features are always enabled for simulators.
5252
struct ConsentDebugSettings {
5353
/// Create a default debug setting, with debugging disabled.

0 commit comments

Comments
 (0)