@@ -1527,6 +1527,132 @@ public final ModelEvaluation importModelEvaluation(ImportModelEvaluationRequest
1527
1527
return stub .importModelEvaluationCallable ();
1528
1528
}
1529
1529
1530
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1531
+ /**
1532
+ * Imports a list of externally generated ModelEvaluationSlice.
1533
+ *
1534
+ * <p>Sample code:
1535
+ *
1536
+ * <pre>{@code
1537
+ * // This snippet has been automatically generated for illustrative purposes only.
1538
+ * // It may require modifications to work in your environment.
1539
+ * try (ModelServiceClient modelServiceClient = ModelServiceClient.create()) {
1540
+ * ModelEvaluationName parent =
1541
+ * ModelEvaluationName.of("[PROJECT]", "[LOCATION]", "[MODEL]", "[EVALUATION]");
1542
+ * List<ModelEvaluationSlice> modelEvaluationSlices = new ArrayList<>();
1543
+ * BatchImportModelEvaluationSlicesResponse response =
1544
+ * modelServiceClient.batchImportModelEvaluationSlices(parent, modelEvaluationSlices);
1545
+ * }
1546
+ * }</pre>
1547
+ *
1548
+ * @param parent Required. The name of the parent ModelEvaluation resource. Format:
1549
+ * `projects/{project}/locations/{location}/models/{model}/evaluations/{evaluation}`
1550
+ * @param modelEvaluationSlices Required. Model evaluation slice resource to be imported.
1551
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1552
+ */
1553
+ public final BatchImportModelEvaluationSlicesResponse batchImportModelEvaluationSlices (
1554
+ ModelEvaluationName parent , List <ModelEvaluationSlice > modelEvaluationSlices ) {
1555
+ BatchImportModelEvaluationSlicesRequest request =
1556
+ BatchImportModelEvaluationSlicesRequest .newBuilder ()
1557
+ .setParent (parent == null ? null : parent .toString ())
1558
+ .addAllModelEvaluationSlices (modelEvaluationSlices )
1559
+ .build ();
1560
+ return batchImportModelEvaluationSlices (request );
1561
+ }
1562
+
1563
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1564
+ /**
1565
+ * Imports a list of externally generated ModelEvaluationSlice.
1566
+ *
1567
+ * <p>Sample code:
1568
+ *
1569
+ * <pre>{@code
1570
+ * // This snippet has been automatically generated for illustrative purposes only.
1571
+ * // It may require modifications to work in your environment.
1572
+ * try (ModelServiceClient modelServiceClient = ModelServiceClient.create()) {
1573
+ * String parent =
1574
+ * ModelEvaluationName.of("[PROJECT]", "[LOCATION]", "[MODEL]", "[EVALUATION]").toString();
1575
+ * List<ModelEvaluationSlice> modelEvaluationSlices = new ArrayList<>();
1576
+ * BatchImportModelEvaluationSlicesResponse response =
1577
+ * modelServiceClient.batchImportModelEvaluationSlices(parent, modelEvaluationSlices);
1578
+ * }
1579
+ * }</pre>
1580
+ *
1581
+ * @param parent Required. The name of the parent ModelEvaluation resource. Format:
1582
+ * `projects/{project}/locations/{location}/models/{model}/evaluations/{evaluation}`
1583
+ * @param modelEvaluationSlices Required. Model evaluation slice resource to be imported.
1584
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1585
+ */
1586
+ public final BatchImportModelEvaluationSlicesResponse batchImportModelEvaluationSlices (
1587
+ String parent , List <ModelEvaluationSlice > modelEvaluationSlices ) {
1588
+ BatchImportModelEvaluationSlicesRequest request =
1589
+ BatchImportModelEvaluationSlicesRequest .newBuilder ()
1590
+ .setParent (parent )
1591
+ .addAllModelEvaluationSlices (modelEvaluationSlices )
1592
+ .build ();
1593
+ return batchImportModelEvaluationSlices (request );
1594
+ }
1595
+
1596
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1597
+ /**
1598
+ * Imports a list of externally generated ModelEvaluationSlice.
1599
+ *
1600
+ * <p>Sample code:
1601
+ *
1602
+ * <pre>{@code
1603
+ * // This snippet has been automatically generated for illustrative purposes only.
1604
+ * // It may require modifications to work in your environment.
1605
+ * try (ModelServiceClient modelServiceClient = ModelServiceClient.create()) {
1606
+ * BatchImportModelEvaluationSlicesRequest request =
1607
+ * BatchImportModelEvaluationSlicesRequest.newBuilder()
1608
+ * .setParent(
1609
+ * ModelEvaluationName.of("[PROJECT]", "[LOCATION]", "[MODEL]", "[EVALUATION]")
1610
+ * .toString())
1611
+ * .addAllModelEvaluationSlices(new ArrayList<ModelEvaluationSlice>())
1612
+ * .build();
1613
+ * BatchImportModelEvaluationSlicesResponse response =
1614
+ * modelServiceClient.batchImportModelEvaluationSlices(request);
1615
+ * }
1616
+ * }</pre>
1617
+ *
1618
+ * @param request The request object containing all of the parameters for the API call.
1619
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1620
+ */
1621
+ public final BatchImportModelEvaluationSlicesResponse batchImportModelEvaluationSlices (
1622
+ BatchImportModelEvaluationSlicesRequest request ) {
1623
+ return batchImportModelEvaluationSlicesCallable ().call (request );
1624
+ }
1625
+
1626
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1627
+ /**
1628
+ * Imports a list of externally generated ModelEvaluationSlice.
1629
+ *
1630
+ * <p>Sample code:
1631
+ *
1632
+ * <pre>{@code
1633
+ * // This snippet has been automatically generated for illustrative purposes only.
1634
+ * // It may require modifications to work in your environment.
1635
+ * try (ModelServiceClient modelServiceClient = ModelServiceClient.create()) {
1636
+ * BatchImportModelEvaluationSlicesRequest request =
1637
+ * BatchImportModelEvaluationSlicesRequest.newBuilder()
1638
+ * .setParent(
1639
+ * ModelEvaluationName.of("[PROJECT]", "[LOCATION]", "[MODEL]", "[EVALUATION]")
1640
+ * .toString())
1641
+ * .addAllModelEvaluationSlices(new ArrayList<ModelEvaluationSlice>())
1642
+ * .build();
1643
+ * ApiFuture<BatchImportModelEvaluationSlicesResponse> future =
1644
+ * modelServiceClient.batchImportModelEvaluationSlicesCallable().futureCall(request);
1645
+ * // Do something.
1646
+ * BatchImportModelEvaluationSlicesResponse response = future.get();
1647
+ * }
1648
+ * }</pre>
1649
+ */
1650
+ public final UnaryCallable <
1651
+ BatchImportModelEvaluationSlicesRequest , BatchImportModelEvaluationSlicesResponse >
1652
+ batchImportModelEvaluationSlicesCallable () {
1653
+ return stub .batchImportModelEvaluationSlicesCallable ();
1654
+ }
1655
+
1530
1656
// AUTO-GENERATED DOCUMENTATION AND METHOD.
1531
1657
/**
1532
1658
* Gets a ModelEvaluation.
0 commit comments