@@ -173,6 +173,133 @@ public final OperationsClient getOperationsClient() {
173173 return operationsClient ;
174174 }
175175
176+ // AUTO-GENERATED DOCUMENTATION AND METHOD
177+ /**
178+ * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
179+ * NOT_FOUND, if the glossary doesn't exist.
180+ *
181+ * <p>Sample code:
182+ *
183+ * <pre><code>
184+ * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
185+ * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
186+ * DeleteGlossaryResponse response = translationServiceClient.deleteGlossaryAsync(name).get();
187+ * }
188+ * </code></pre>
189+ *
190+ * @param name Required. The name of the glossary to delete.
191+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
192+ */
193+ @ BetaApi (
194+ "The surface for long-running operations is not stable yet and may change in the future." )
195+ public final OperationFuture <DeleteGlossaryResponse , DeleteGlossaryMetadata > deleteGlossaryAsync (
196+ GlossaryName name ) {
197+ DeleteGlossaryRequest request =
198+ DeleteGlossaryRequest .newBuilder ().setName (name == null ? null : name .toString ()).build ();
199+ return deleteGlossaryAsync (request );
200+ }
201+
202+ // AUTO-GENERATED DOCUMENTATION AND METHOD
203+ /**
204+ * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
205+ * NOT_FOUND, if the glossary doesn't exist.
206+ *
207+ * <p>Sample code:
208+ *
209+ * <pre><code>
210+ * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
211+ * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
212+ * DeleteGlossaryResponse response = translationServiceClient.deleteGlossaryAsync(name.toString()).get();
213+ * }
214+ * </code></pre>
215+ *
216+ * @param name Required. The name of the glossary to delete.
217+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
218+ */
219+ @ BetaApi (
220+ "The surface for long-running operations is not stable yet and may change in the future." )
221+ public final OperationFuture <DeleteGlossaryResponse , DeleteGlossaryMetadata > deleteGlossaryAsync (
222+ String name ) {
223+ DeleteGlossaryRequest request = DeleteGlossaryRequest .newBuilder ().setName (name ).build ();
224+ return deleteGlossaryAsync (request );
225+ }
226+
227+ // AUTO-GENERATED DOCUMENTATION AND METHOD
228+ /**
229+ * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
230+ * NOT_FOUND, if the glossary doesn't exist.
231+ *
232+ * <p>Sample code:
233+ *
234+ * <pre><code>
235+ * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
236+ * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
237+ * DeleteGlossaryRequest request = DeleteGlossaryRequest.newBuilder()
238+ * .setName(name.toString())
239+ * .build();
240+ * DeleteGlossaryResponse response = translationServiceClient.deleteGlossaryAsync(request).get();
241+ * }
242+ * </code></pre>
243+ *
244+ * @param request The request object containing all of the parameters for the API call.
245+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
246+ */
247+ @ BetaApi (
248+ "The surface for long-running operations is not stable yet and may change in the future." )
249+ public final OperationFuture <DeleteGlossaryResponse , DeleteGlossaryMetadata > deleteGlossaryAsync (
250+ DeleteGlossaryRequest request ) {
251+ return deleteGlossaryOperationCallable ().futureCall (request );
252+ }
253+
254+ // AUTO-GENERATED DOCUMENTATION AND METHOD
255+ /**
256+ * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
257+ * NOT_FOUND, if the glossary doesn't exist.
258+ *
259+ * <p>Sample code:
260+ *
261+ * <pre><code>
262+ * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
263+ * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
264+ * DeleteGlossaryRequest request = DeleteGlossaryRequest.newBuilder()
265+ * .setName(name.toString())
266+ * .build();
267+ * OperationFuture<DeleteGlossaryResponse, DeleteGlossaryMetadata> future = translationServiceClient.deleteGlossaryOperationCallable().futureCall(request);
268+ * // Do something
269+ * DeleteGlossaryResponse response = future.get();
270+ * }
271+ * </code></pre>
272+ */
273+ @ BetaApi ("The surface for use by generated code is not stable yet and may change in the future." )
274+ public final OperationCallable <
275+ DeleteGlossaryRequest , DeleteGlossaryResponse , DeleteGlossaryMetadata >
276+ deleteGlossaryOperationCallable () {
277+ return stub .deleteGlossaryOperationCallable ();
278+ }
279+
280+ // AUTO-GENERATED DOCUMENTATION AND METHOD
281+ /**
282+ * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
283+ * NOT_FOUND, if the glossary doesn't exist.
284+ *
285+ * <p>Sample code:
286+ *
287+ * <pre><code>
288+ * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
289+ * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
290+ * DeleteGlossaryRequest request = DeleteGlossaryRequest.newBuilder()
291+ * .setName(name.toString())
292+ * .build();
293+ * ApiFuture<Operation> future = translationServiceClient.deleteGlossaryCallable().futureCall(request);
294+ * // Do something
295+ * Operation response = future.get();
296+ * }
297+ * </code></pre>
298+ */
299+ public final UnaryCallable <DeleteGlossaryRequest , Operation > deleteGlossaryCallable () {
300+ return stub .deleteGlossaryCallable ();
301+ }
302+
176303 // AUTO-GENERATED DOCUMENTATION AND METHOD
177304 /**
178305 * Translates input text and returns translated text.
@@ -1191,133 +1318,6 @@ public final UnaryCallable<GetGlossaryRequest, Glossary> getGlossaryCallable() {
11911318 return stub .getGlossaryCallable ();
11921319 }
11931320
1194- // AUTO-GENERATED DOCUMENTATION AND METHOD
1195- /**
1196- * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
1197- * NOT_FOUND, if the glossary doesn't exist.
1198- *
1199- * <p>Sample code:
1200- *
1201- * <pre><code>
1202- * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
1203- * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
1204- * DeleteGlossaryResponse response = translationServiceClient.deleteGlossaryAsync(name).get();
1205- * }
1206- * </code></pre>
1207- *
1208- * @param name Required. The name of the glossary to delete.
1209- * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1210- */
1211- @ BetaApi (
1212- "The surface for long-running operations is not stable yet and may change in the future." )
1213- public final OperationFuture <DeleteGlossaryResponse , DeleteGlossaryMetadata > deleteGlossaryAsync (
1214- GlossaryName name ) {
1215- DeleteGlossaryRequest request =
1216- DeleteGlossaryRequest .newBuilder ().setName (name == null ? null : name .toString ()).build ();
1217- return deleteGlossaryAsync (request );
1218- }
1219-
1220- // AUTO-GENERATED DOCUMENTATION AND METHOD
1221- /**
1222- * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
1223- * NOT_FOUND, if the glossary doesn't exist.
1224- *
1225- * <p>Sample code:
1226- *
1227- * <pre><code>
1228- * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
1229- * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
1230- * DeleteGlossaryResponse response = translationServiceClient.deleteGlossaryAsync(name.toString()).get();
1231- * }
1232- * </code></pre>
1233- *
1234- * @param name Required. The name of the glossary to delete.
1235- * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1236- */
1237- @ BetaApi (
1238- "The surface for long-running operations is not stable yet and may change in the future." )
1239- public final OperationFuture <DeleteGlossaryResponse , DeleteGlossaryMetadata > deleteGlossaryAsync (
1240- String name ) {
1241- DeleteGlossaryRequest request = DeleteGlossaryRequest .newBuilder ().setName (name ).build ();
1242- return deleteGlossaryAsync (request );
1243- }
1244-
1245- // AUTO-GENERATED DOCUMENTATION AND METHOD
1246- /**
1247- * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
1248- * NOT_FOUND, if the glossary doesn't exist.
1249- *
1250- * <p>Sample code:
1251- *
1252- * <pre><code>
1253- * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
1254- * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
1255- * DeleteGlossaryRequest request = DeleteGlossaryRequest.newBuilder()
1256- * .setName(name.toString())
1257- * .build();
1258- * DeleteGlossaryResponse response = translationServiceClient.deleteGlossaryAsync(request).get();
1259- * }
1260- * </code></pre>
1261- *
1262- * @param request The request object containing all of the parameters for the API call.
1263- * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1264- */
1265- @ BetaApi (
1266- "The surface for long-running operations is not stable yet and may change in the future." )
1267- public final OperationFuture <DeleteGlossaryResponse , DeleteGlossaryMetadata > deleteGlossaryAsync (
1268- DeleteGlossaryRequest request ) {
1269- return deleteGlossaryOperationCallable ().futureCall (request );
1270- }
1271-
1272- // AUTO-GENERATED DOCUMENTATION AND METHOD
1273- /**
1274- * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
1275- * NOT_FOUND, if the glossary doesn't exist.
1276- *
1277- * <p>Sample code:
1278- *
1279- * <pre><code>
1280- * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
1281- * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
1282- * DeleteGlossaryRequest request = DeleteGlossaryRequest.newBuilder()
1283- * .setName(name.toString())
1284- * .build();
1285- * OperationFuture<DeleteGlossaryResponse, DeleteGlossaryMetadata> future = translationServiceClient.deleteGlossaryOperationCallable().futureCall(request);
1286- * // Do something
1287- * DeleteGlossaryResponse response = future.get();
1288- * }
1289- * </code></pre>
1290- */
1291- @ BetaApi ("The surface for use by generated code is not stable yet and may change in the future." )
1292- public final OperationCallable <
1293- DeleteGlossaryRequest , DeleteGlossaryResponse , DeleteGlossaryMetadata >
1294- deleteGlossaryOperationCallable () {
1295- return stub .deleteGlossaryOperationCallable ();
1296- }
1297-
1298- // AUTO-GENERATED DOCUMENTATION AND METHOD
1299- /**
1300- * Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns
1301- * NOT_FOUND, if the glossary doesn't exist.
1302- *
1303- * <p>Sample code:
1304- *
1305- * <pre><code>
1306- * try (TranslationServiceClient translationServiceClient = TranslationServiceClient.create()) {
1307- * GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
1308- * DeleteGlossaryRequest request = DeleteGlossaryRequest.newBuilder()
1309- * .setName(name.toString())
1310- * .build();
1311- * ApiFuture<Operation> future = translationServiceClient.deleteGlossaryCallable().futureCall(request);
1312- * // Do something
1313- * Operation response = future.get();
1314- * }
1315- * </code></pre>
1316- */
1317- public final UnaryCallable <DeleteGlossaryRequest , Operation > deleteGlossaryCallable () {
1318- return stub .deleteGlossaryCallable ();
1319- }
1320-
13211321 @ Override
13221322 public final void close () {
13231323 stub .close ();
0 commit comments