/** * Gets a single notification channel. The channel includes the relevant configuration details * with which the channel was created. However, the response may truncate or omit passwords, API * keys, or other private key matter and thus the response may not be 100% identical to the * information that was supplied in the call to the create method. * * <p>Sample code: * * <pre><code> * try (NotificationChannelServiceClient notificationChannelServiceClient = NotificationChannelServiceClient.create()) { * NotificationChannelName name = NotificationChannelName.of("[PROJECT]", "[NOTIFICATION_CHANNEL]"); * NotificationChannel response = notificationChannelServiceClient.getNotificationChannel(name); * } * </code></pre> * * @param name The channel for which to execute the request. The format is * `projects/[PROJECT_ID]/notificationChannels/[CHANNEL_ID]`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final NotificationChannel getNotificationChannel(NotificationChannelName name) { GetNotificationChannelRequest request = GetNotificationChannelRequest.newBuilder() .setName(name == null ? null : name.toString()) .build(); return getNotificationChannel(request); }
/** * Gets a single notification channel. The channel includes the relevant configuration details * with which the channel was created. However, the response may truncate or omit passwords, API * keys, or other private key matter and thus the response may not be 100% identical to the * information that was supplied in the call to the create method. * * <p>Sample code: * * <pre><code> * try (NotificationChannelServiceClient notificationChannelServiceClient = NotificationChannelServiceClient.create()) { * NotificationChannelName name = NotificationChannelName.of("[PROJECT]", "[NOTIFICATION_CHANNEL]"); * NotificationChannel response = notificationChannelServiceClient.getNotificationChannel(name.toString()); * } * </code></pre> * * @param name The channel for which to execute the request. The format is * `projects/[PROJECT_ID]/notificationChannels/[CHANNEL_ID]`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final NotificationChannel getNotificationChannel(String name) { GetNotificationChannelRequest request = GetNotificationChannelRequest.newBuilder().setName(name).build(); return getNotificationChannel(request); }
/** * Gets a single notification channel. The channel includes the relevant configuration details * with which the channel was created. However, the response may truncate or omit passwords, API * keys, or other private key matter and thus the response may not be 100% identical to the * information that was supplied in the call to the create method. * * <p>Sample code: * * <pre><code> * try (NotificationChannelServiceClient notificationChannelServiceClient = NotificationChannelServiceClient.create()) { * NotificationChannelName name = NotificationChannelName.of("[PROJECT]", "[NOTIFICATION_CHANNEL]"); * NotificationChannel response = notificationChannelServiceClient.getNotificationChannel(name); * } * </code></pre> * * @param name The channel for which to execute the request. The format is * `projects/[PROJECT_ID]/notificationChannels/[CHANNEL_ID]`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final NotificationChannel getNotificationChannel(NotificationChannelName name) { GetNotificationChannelRequest request = GetNotificationChannelRequest.newBuilder() .setName(name == null ? null : name.toString()) .build(); return getNotificationChannel(request); }
/** * Gets a single notification channel. The channel includes the relevant configuration details * with which the channel was created. However, the response may truncate or omit passwords, API * keys, or other private key matter and thus the response may not be 100% identical to the * information that was supplied in the call to the create method. * * <p>Sample code: * * <pre><code> * try (NotificationChannelServiceClient notificationChannelServiceClient = NotificationChannelServiceClient.create()) { * NotificationChannelName name = NotificationChannelName.of("[PROJECT]", "[NOTIFICATION_CHANNEL]"); * NotificationChannel response = notificationChannelServiceClient.getNotificationChannel(name.toString()); * } * </code></pre> * * @param name The channel for which to execute the request. The format is * `projects/[PROJECT_ID]/notificationChannels/[CHANNEL_ID]`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final NotificationChannel getNotificationChannel(String name) { GetNotificationChannelRequest request = GetNotificationChannelRequest.newBuilder().setName(name).build(); return getNotificationChannel(request); }