@@ -36,23 +36,43 @@ FIREBASE_APP_REGISTER_CALLBACKS_REFERENCE(admob)
36
36
37
37
namespace firebase {
38
38
39
+ // / @deprecated The functionality in the <code>firebase::admob</code> namespace
40
+ // / has been replaced by the Google Mobile Ads SDK in the
41
+ // / <code>firebase::gma</code> namespace. Learn how to transition to the new
42
+ // / SDK in our <a href="/docs/admob/cpp/admob-migration">migration guide</a>.
43
+ // /
39
44
// / @brief API for AdMob with Firebase.
40
45
// /
41
46
// / The AdMob API allows you to load and display mobile ads using the Google
42
47
// / Mobile Ads SDK. Each ad format has its own header file.
43
48
namespace admob {
44
49
45
- // / Initializes AdMob via Firebase.
50
+ // / @deprecated
51
+ // / @brief Initializes AdMob via Firebase.
52
+ // /
53
+ // / The functionality in the <code>firebase::admob</code> namespace has
54
+ // / been replaced by the Google Mobile Ads SDK in the
55
+ // / <code>firebase::gma</code> namespace. Learn how to transition to the
56
+ // / new SDK in our <a href="/docs/admob/cpp/admob-migration">migration
57
+ // / guide</a>.
46
58
// /
47
59
// / @param app The Firebase app for which to initialize mobile ads.
48
60
// /
49
61
// / @return kInitResultSuccess if initialization succeeded, or
50
62
// / kInitResultFailedMissingDependency on Android if Google Play services is not
51
63
// / available on the current device and the Google Mobile Ads SDK requires
52
64
// / Google Play services (for example, when using 'play-services-ads-lite').
53
- InitResult Initialize (const ::firebase::App& app);
65
+ FIREBASE_DEPRECATED InitResult Initialize (const ::firebase::App& app);
54
66
55
- // / Initializes AdMob via Firebase with the publisher's AdMob app ID.
67
+ // / @deprecated
68
+ // / @brief Initializes AdMob via Firebase with the publisher's AdMob app ID.
69
+ // /
70
+ // / The functionality in the <code>firebase::admob</code> namespace has
71
+ // / been replaced by the Google Mobile Ads SDK in the
72
+ // / <code>firebase::gma</code> namespace. Learn how to transition to the
73
+ // / new SDK in our <a href="/docs/admob/cpp/admob-migration">migration
74
+ // / guide</a>.
75
+ // /
56
76
// / Initializing the Google Mobile Ads SDK with the AdMob app ID at app launch
57
77
// / allows the SDK to fetch app-level settings and perform configuration tasks
58
78
// / as early as possible. This can help reduce latency for the initial ad
@@ -69,10 +89,18 @@ InitResult Initialize(const ::firebase::App& app);
69
89
// / kInitResultFailedMissingDependency on Android if Google Play services is not
70
90
// / available on the current device and the Google Mobile Ads SDK requires
71
91
// / Google Play services (for example, when using 'play-services-ads-lite').
72
- InitResult Initialize (const ::firebase::App& app, const char * admob_app_id);
92
+ FIREBASE_DEPRECATED InitResult Initialize (const ::firebase::App& app,
93
+ const char * admob_app_id);
73
94
74
95
#if FIREBASE_PLATFORM_ANDROID || defined(DOXYGEN)
75
- // / Initializes AdMob without Firebase for Android.
96
+ // / @deprecated
97
+ // / @brief Initializes AdMob without Firebase for Android.
98
+ // /
99
+ // / The functionality in the <code>firebase::admob</code> namespace has
100
+ // / been replaced by the Google Mobile Ads SDK in the
101
+ // / <code>firebase::gma</code> namespace. Learn how to transition to the
102
+ // / new SDK in our <a href="/docs/admob/cpp/admob-migration">migration
103
+ // / guide</a>.
76
104
// /
77
105
// / The arguments to @ref Initialize are platform-specific so the caller must do
78
106
// / something like this:
@@ -91,9 +119,17 @@ InitResult Initialize(const ::firebase::App& app, const char* admob_app_id);
91
119
// / kInitResultFailedMissingDependency on Android if Google Play services is not
92
120
// / available on the current device and the AdMob SDK requires
93
121
// / Google Play services (for example when using 'play-services-ads-lite').
94
- InitResult Initialize (JNIEnv* jni_env, jobject activity);
122
+ FIREBASE_DEPRECATED InitResult Initialize (JNIEnv* jni_env, jobject activity);
95
123
96
- // / Initializes AdMob via Firebase with the publisher's AdMob app ID.
124
+ // / @deprecated
125
+ // / @brief Initializes AdMob via Firebase with the publisher's AdMob app ID.
126
+ // /
127
+ // / The functionality in the <code>firebase::admob</code> namespace has
128
+ // / been replaced by the Google Mobile Ads SDK in the
129
+ // / <code>firebase::gma</code> namespace. Learn how to transition to the
130
+ // / new SDK in our <a href="/docs/admob/cpp/admob-migration">migration
131
+ // / guide</a>.
132
+ // /
97
133
// / Initializing the Google Mobile Ads SDK with the AdMob app ID at app launch
98
134
// / allows the SDK to fetch app-level settings and perform configuration tasks
99
135
// / as early as possible. This can help reduce latency for the initial ad
@@ -121,15 +157,30 @@ InitResult Initialize(JNIEnv* jni_env, jobject activity);
121
157
// / kInitResultFailedMissingDependency on Android if Google Play services is not
122
158
// / available on the current device and the AdMob SDK requires
123
159
// / Google Play services (for example when using 'play-services-ads-lite').
124
- InitResult Initialize (JNIEnv* jni_env, jobject activity,
125
- const char * admob_app_id);
160
+ FIREBASE_DEPRECATED InitResult Initialize (JNIEnv* jni_env, jobject activity,
161
+ const char * admob_app_id);
126
162
#endif // defined(__ANDROID__) || defined(DOXYGEN)
127
163
#if !FIREBASE_PLATFORM_ANDROID || defined(DOXYGEN)
128
- // / Initializes AdMob without Firebase for iOS.
129
- InitResult Initialize ();
164
+ // / @deprecated
165
+ // / @brief Initializes AdMob without Firebase for iOS.
166
+ // /
167
+ // / The functionality in the <code>firebase::admob</code> namespace has
168
+ // / been replaced by the Google Mobile Ads SDK in the
169
+ // / <code>firebase::gma</code> namespace. Learn how to transition to the
170
+ // / new SDK in our <a href="/docs/admob/cpp/admob-migration">migration
171
+ // / guide</a>.
172
+ FIREBASE_DEPRECATED InitResult Initialize ();
130
173
131
- // / Initializes AdMob with the publisher's AdMob app ID and without Firebase for
132
- // / iOS.
174
+ // / @deprecated
175
+ // / @brief Initializes AdMob with the publisher's AdMob app ID and without
176
+ // / Firebase for iOS.
177
+ // /
178
+ // / The functionality in the <code>firebase::admob</code> namespace has
179
+ // / been replaced by the Google Mobile Ads SDK in the
180
+ // / <code>firebase::gma</code> namespace. Learn how to transition to the
181
+ // / new SDK in our <a href="/docs/admob/cpp/admob-migration">migration
182
+ // / guide</a>.
183
+ // /
133
184
// / Initializing the Google Mobile Ads SDK with the AdMob app ID at app launch
134
185
// / allows the SDK to fetch app-level settings and perform configuration tasks
135
186
// / as early as possible. This can help reduce latency for the initial ad
@@ -142,14 +193,21 @@ InitResult Initialize();
142
193
// / @param[in] admob_app_id The publisher's AdMob app ID.
143
194
// /
144
195
// / @return kInitResultSuccess if initialization succeeded
145
- InitResult Initialize (const char * admob_app_id);
196
+ FIREBASE_DEPRECATED InitResult Initialize (const char * admob_app_id);
146
197
#endif // !defined(__ANDROID__) || defined(DOXYGEN)
147
198
199
+ // / @deprecated
148
200
// / @brief Terminate AdMob.
149
201
// /
202
+ // / The functionality in the <code>firebase::admob</code> namespace has
203
+ // / been replaced by the Google Mobile Ads SDK in the
204
+ // / <code>firebase::gma</code> namespace. Learn how to transition to the
205
+ // / new SDK in our <a href="/docs/admob/cpp/admob-migration">migration
206
+ // / guide</a>.
207
+ // /
150
208
// / Frees resources associated with AdMob that were allocated during
151
209
// / @ref firebase::admob::Initialize().
152
- void Terminate ();
210
+ FIREBASE_DEPRECATED void Terminate ();
153
211
154
212
} // namespace admob
155
213
} // namespace firebase
0 commit comments