47
47
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
48
48
* try (AdvisoryNotificationsServiceClient advisoryNotificationsServiceClient =
49
49
* AdvisoryNotificationsServiceClient.create()) {
50
- * NotificationName name = NotificationName.of("[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]");
50
+ * NotificationName name =
51
+ * NotificationName.ofOrganizationLocationNotificationName(
52
+ * "[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]");
51
53
* Notification response = advisoryNotificationsServiceClient.getNotification(name);
52
54
* }
53
55
* }</pre>
@@ -194,7 +196,7 @@ public AdvisoryNotificationsServiceStub getStub() {
194
196
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
195
197
* try (AdvisoryNotificationsServiceClient advisoryNotificationsServiceClient =
196
198
* AdvisoryNotificationsServiceClient.create()) {
197
- * LocationName parent = LocationName.of ("[ORGANIZATION]", "[LOCATION]");
199
+ * LocationName parent = LocationName.ofOrganizationLocationName ("[ORGANIZATION]", "[LOCATION]");
198
200
* for (Notification element :
199
201
* advisoryNotificationsServiceClient.listNotifications(parent).iterateAll()) {
200
202
* // doThingsWith(element);
@@ -203,7 +205,8 @@ public AdvisoryNotificationsServiceStub getStub() {
203
205
* }</pre>
204
206
*
205
207
* @param parent Required. The parent, which owns this collection of notifications. Must be of the
206
- * form "organizations/{organization}/locations/{location}".
208
+ * form "organizations/{organization}/locations/{location}" or
209
+ * "projects/{project}/locations/{location}"
207
210
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
208
211
*/
209
212
public final ListNotificationsPagedResponse listNotifications (LocationName parent ) {
@@ -228,7 +231,8 @@ public final ListNotificationsPagedResponse listNotifications(LocationName paren
228
231
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
229
232
* try (AdvisoryNotificationsServiceClient advisoryNotificationsServiceClient =
230
233
* AdvisoryNotificationsServiceClient.create()) {
231
- * String parent = LocationName.of("[ORGANIZATION]", "[LOCATION]").toString();
234
+ * String parent =
235
+ * LocationName.ofOrganizationLocationName("[ORGANIZATION]", "[LOCATION]").toString();
232
236
* for (Notification element :
233
237
* advisoryNotificationsServiceClient.listNotifications(parent).iterateAll()) {
234
238
* // doThingsWith(element);
@@ -237,7 +241,8 @@ public final ListNotificationsPagedResponse listNotifications(LocationName paren
237
241
* }</pre>
238
242
*
239
243
* @param parent Required. The parent, which owns this collection of notifications. Must be of the
240
- * form "organizations/{organization}/locations/{location}".
244
+ * form "organizations/{organization}/locations/{location}" or
245
+ * "projects/{project}/locations/{location}"
241
246
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
242
247
*/
243
248
public final ListNotificationsPagedResponse listNotifications (String parent ) {
@@ -262,7 +267,9 @@ public final ListNotificationsPagedResponse listNotifications(String parent) {
262
267
* AdvisoryNotificationsServiceClient.create()) {
263
268
* ListNotificationsRequest request =
264
269
* ListNotificationsRequest.newBuilder()
265
- * .setParent(LocationName.of("[ORGANIZATION]", "[LOCATION]").toString())
270
+ * .setParent(
271
+ * LocationName.ofOrganizationLocationName("[ORGANIZATION]", "[LOCATION]")
272
+ * .toString())
266
273
* .setPageSize(883849137)
267
274
* .setPageToken("pageToken873572522")
268
275
* .setView(NotificationView.forNumber(0))
@@ -298,7 +305,9 @@ public final ListNotificationsPagedResponse listNotifications(ListNotificationsR
298
305
* AdvisoryNotificationsServiceClient.create()) {
299
306
* ListNotificationsRequest request =
300
307
* ListNotificationsRequest.newBuilder()
301
- * .setParent(LocationName.of("[ORGANIZATION]", "[LOCATION]").toString())
308
+ * .setParent(
309
+ * LocationName.ofOrganizationLocationName("[ORGANIZATION]", "[LOCATION]")
310
+ * .toString())
302
311
* .setPageSize(883849137)
303
312
* .setPageToken("pageToken873572522")
304
313
* .setView(NotificationView.forNumber(0))
@@ -334,7 +343,9 @@ public final ListNotificationsPagedResponse listNotifications(ListNotificationsR
334
343
* AdvisoryNotificationsServiceClient.create()) {
335
344
* ListNotificationsRequest request =
336
345
* ListNotificationsRequest.newBuilder()
337
- * .setParent(LocationName.of("[ORGANIZATION]", "[LOCATION]").toString())
346
+ * .setParent(
347
+ * LocationName.ofOrganizationLocationName("[ORGANIZATION]", "[LOCATION]")
348
+ * .toString())
338
349
* .setPageSize(883849137)
339
350
* .setPageToken("pageToken873572522")
340
351
* .setView(NotificationView.forNumber(0))
@@ -375,13 +386,16 @@ public final ListNotificationsPagedResponse listNotifications(ListNotificationsR
375
386
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
376
387
* try (AdvisoryNotificationsServiceClient advisoryNotificationsServiceClient =
377
388
* AdvisoryNotificationsServiceClient.create()) {
378
- * NotificationName name = NotificationName.of("[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]");
389
+ * NotificationName name =
390
+ * NotificationName.ofOrganizationLocationNotificationName(
391
+ * "[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]");
379
392
* Notification response = advisoryNotificationsServiceClient.getNotification(name);
380
393
* }
381
394
* }</pre>
382
395
*
383
396
* @param name Required. A name of the notification to retrieve. Format:
384
- * organizations/{organization}/locations/{location}/notifications/{notification}.
397
+ * organizations/{organization}/locations/{location}/notifications/{notification} or
398
+ * projects/{projects}/locations/{location}/notifications/{notification}.
385
399
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
386
400
*/
387
401
public final Notification getNotification (NotificationName name ) {
@@ -405,13 +419,16 @@ public final Notification getNotification(NotificationName name) {
405
419
* try (AdvisoryNotificationsServiceClient advisoryNotificationsServiceClient =
406
420
* AdvisoryNotificationsServiceClient.create()) {
407
421
* String name =
408
- * NotificationName.of("[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]").toString();
422
+ * NotificationName.ofOrganizationLocationNotificationName(
423
+ * "[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]")
424
+ * .toString();
409
425
* Notification response = advisoryNotificationsServiceClient.getNotification(name);
410
426
* }
411
427
* }</pre>
412
428
*
413
429
* @param name Required. A name of the notification to retrieve. Format:
414
- * organizations/{organization}/locations/{location}/notifications/{notification}.
430
+ * organizations/{organization}/locations/{location}/notifications/{notification} or
431
+ * projects/{projects}/locations/{location}/notifications/{notification}.
415
432
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
416
433
*/
417
434
public final Notification getNotification (String name ) {
@@ -436,7 +453,9 @@ public final Notification getNotification(String name) {
436
453
* GetNotificationRequest request =
437
454
* GetNotificationRequest.newBuilder()
438
455
* .setName(
439
- * NotificationName.of("[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]").toString())
456
+ * NotificationName.ofOrganizationLocationNotificationName(
457
+ * "[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]")
458
+ * .toString())
440
459
* .setLanguageCode("languageCode-2092349083")
441
460
* .build();
442
461
* Notification response = advisoryNotificationsServiceClient.getNotification(request);
@@ -467,7 +486,9 @@ public final Notification getNotification(GetNotificationRequest request) {
467
486
* GetNotificationRequest request =
468
487
* GetNotificationRequest.newBuilder()
469
488
* .setName(
470
- * NotificationName.of("[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]").toString())
489
+ * NotificationName.ofOrganizationLocationNotificationName(
490
+ * "[ORGANIZATION]", "[LOCATION]", "[NOTIFICATION]")
491
+ * .toString())
471
492
* .setLanguageCode("languageCode-2092349083")
472
493
* .build();
473
494
* ApiFuture<Notification> future =
0 commit comments