1 | <?php
|
---|
2 | /*
|
---|
3 | * Copyright 2014 Google Inc.
|
---|
4 | *
|
---|
5 | * Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
---|
6 | * use this file except in compliance with the License. You may obtain a copy of
|
---|
7 | * the License at
|
---|
8 | *
|
---|
9 | * http://www.apache.org/licenses/LICENSE-2.0
|
---|
10 | *
|
---|
11 | * Unless required by applicable law or agreed to in writing, software
|
---|
12 | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
---|
13 | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
---|
14 | * License for the specific language governing permissions and limitations under
|
---|
15 | * the License.
|
---|
16 | */
|
---|
17 |
|
---|
18 | namespace Google\Service\Aiplatform\Resource;
|
---|
19 |
|
---|
20 | use Google\Service\Aiplatform\GoogleCloudAiplatformV1ListMetadataStoresResponse;
|
---|
21 | use Google\Service\Aiplatform\GoogleCloudAiplatformV1MetadataStore;
|
---|
22 | use Google\Service\Aiplatform\GoogleLongrunningOperation;
|
---|
23 |
|
---|
24 | /**
|
---|
25 | * The "metadataStores" collection of methods.
|
---|
26 | * Typical usage is:
|
---|
27 | * <code>
|
---|
28 | * $aiplatformService = new Google\Service\Aiplatform(...);
|
---|
29 | * $metadataStores = $aiplatformService->projects_locations_metadataStores;
|
---|
30 | * </code>
|
---|
31 | */
|
---|
32 | class ProjectsLocationsMetadataStores extends \Google\Service\Resource
|
---|
33 | {
|
---|
34 | /**
|
---|
35 | * Initializes a MetadataStore, including allocation of resources.
|
---|
36 | * (metadataStores.create)
|
---|
37 | *
|
---|
38 | * @param string $parent Required. The resource name of the Location where the
|
---|
39 | * MetadataStore should be created. Format:
|
---|
40 | * `projects/{project}/locations/{location}/`
|
---|
41 | * @param GoogleCloudAiplatformV1MetadataStore $postBody
|
---|
42 | * @param array $optParams Optional parameters.
|
---|
43 | *
|
---|
44 | * @opt_param string metadataStoreId The {metadatastore} portion of the resource
|
---|
45 | * name with the format:
|
---|
46 | * `projects/{project}/locations/{location}/metadataStores/{metadatastore}` If
|
---|
47 | * not provided, the MetadataStore's ID will be a UUID generated by the service.
|
---|
48 | * Must be 4-128 characters in length. Valid characters are `/a-z-/`. Must be
|
---|
49 | * unique across all MetadataStores in the parent Location. (Otherwise the
|
---|
50 | * request will fail with ALREADY_EXISTS, or PERMISSION_DENIED if the caller
|
---|
51 | * can't view the preexisting MetadataStore.)
|
---|
52 | * @return GoogleLongrunningOperation
|
---|
53 | * @throws \Google\Service\Exception
|
---|
54 | */
|
---|
55 | public function create($parent, GoogleCloudAiplatformV1MetadataStore $postBody, $optParams = [])
|
---|
56 | {
|
---|
57 | $params = ['parent' => $parent, 'postBody' => $postBody];
|
---|
58 | $params = array_merge($params, $optParams);
|
---|
59 | return $this->call('create', [$params], GoogleLongrunningOperation::class);
|
---|
60 | }
|
---|
61 | /**
|
---|
62 | * Deletes a single MetadataStore and all its child resources (Artifacts,
|
---|
63 | * Executions, and Contexts). (metadataStores.delete)
|
---|
64 | *
|
---|
65 | * @param string $name Required. The resource name of the MetadataStore to
|
---|
66 | * delete. Format:
|
---|
67 | * `projects/{project}/locations/{location}/metadataStores/{metadatastore}`
|
---|
68 | * @param array $optParams Optional parameters.
|
---|
69 | *
|
---|
70 | * @opt_param bool force Deprecated: Field is no longer supported.
|
---|
71 | * @return GoogleLongrunningOperation
|
---|
72 | * @throws \Google\Service\Exception
|
---|
73 | */
|
---|
74 | public function delete($name, $optParams = [])
|
---|
75 | {
|
---|
76 | $params = ['name' => $name];
|
---|
77 | $params = array_merge($params, $optParams);
|
---|
78 | return $this->call('delete', [$params], GoogleLongrunningOperation::class);
|
---|
79 | }
|
---|
80 | /**
|
---|
81 | * Retrieves a specific MetadataStore. (metadataStores.get)
|
---|
82 | *
|
---|
83 | * @param string $name Required. The resource name of the MetadataStore to
|
---|
84 | * retrieve. Format:
|
---|
85 | * `projects/{project}/locations/{location}/metadataStores/{metadatastore}`
|
---|
86 | * @param array $optParams Optional parameters.
|
---|
87 | * @return GoogleCloudAiplatformV1MetadataStore
|
---|
88 | * @throws \Google\Service\Exception
|
---|
89 | */
|
---|
90 | public function get($name, $optParams = [])
|
---|
91 | {
|
---|
92 | $params = ['name' => $name];
|
---|
93 | $params = array_merge($params, $optParams);
|
---|
94 | return $this->call('get', [$params], GoogleCloudAiplatformV1MetadataStore::class);
|
---|
95 | }
|
---|
96 | /**
|
---|
97 | * Lists MetadataStores for a Location.
|
---|
98 | * (metadataStores.listProjectsLocationsMetadataStores)
|
---|
99 | *
|
---|
100 | * @param string $parent Required. The Location whose MetadataStores should be
|
---|
101 | * listed. Format: `projects/{project}/locations/{location}`
|
---|
102 | * @param array $optParams Optional parameters.
|
---|
103 | *
|
---|
104 | * @opt_param int pageSize The maximum number of Metadata Stores to return. The
|
---|
105 | * service may return fewer. Must be in range 1-1000, inclusive. Defaults to
|
---|
106 | * 100.
|
---|
107 | * @opt_param string pageToken A page token, received from a previous
|
---|
108 | * MetadataService.ListMetadataStores call. Provide this to retrieve the
|
---|
109 | * subsequent page. When paginating, all other provided parameters must match
|
---|
110 | * the call that provided the page token. (Otherwise the request will fail with
|
---|
111 | * INVALID_ARGUMENT error.)
|
---|
112 | * @return GoogleCloudAiplatformV1ListMetadataStoresResponse
|
---|
113 | * @throws \Google\Service\Exception
|
---|
114 | */
|
---|
115 | public function listProjectsLocationsMetadataStores($parent, $optParams = [])
|
---|
116 | {
|
---|
117 | $params = ['parent' => $parent];
|
---|
118 | $params = array_merge($params, $optParams);
|
---|
119 | return $this->call('list', [$params], GoogleCloudAiplatformV1ListMetadataStoresResponse::class);
|
---|
120 | }
|
---|
121 | }
|
---|
122 |
|
---|
123 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
124 | class_alias(ProjectsLocationsMetadataStores::class, 'Google_Service_Aiplatform_Resource_ProjectsLocationsMetadataStores');
|
---|