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\DataCatalog\Resource;
|
---|
19 |
|
---|
20 | use Google\Service\DataCatalog\GoogleCloudDatacatalogV1MigrationConfig;
|
---|
21 | use Google\Service\DataCatalog\GoogleCloudDatacatalogV1OrganizationConfig;
|
---|
22 | use Google\Service\DataCatalog\GoogleCloudDatacatalogV1SetConfigRequest;
|
---|
23 |
|
---|
24 | /**
|
---|
25 | * The "locations" collection of methods.
|
---|
26 | * Typical usage is:
|
---|
27 | * <code>
|
---|
28 | * $datacatalogService = new Google\Service\DataCatalog(...);
|
---|
29 | * $locations = $datacatalogService->organizations_locations;
|
---|
30 | * </code>
|
---|
31 | */
|
---|
32 | class OrganizationsLocations extends \Google\Service\Resource
|
---|
33 | {
|
---|
34 | /**
|
---|
35 | * Retrieves the configuration related to the migration from Data Catalog to
|
---|
36 | * Dataplex for a specific organization, including all the projects under it
|
---|
37 | * which have a separate configuration set. (locations.retrieveConfig)
|
---|
38 | *
|
---|
39 | * @param string $name Required. The organization whose config is being
|
---|
40 | * retrieved.
|
---|
41 | * @param array $optParams Optional parameters.
|
---|
42 | * @return GoogleCloudDatacatalogV1OrganizationConfig
|
---|
43 | * @throws \Google\Service\Exception
|
---|
44 | */
|
---|
45 | public function retrieveConfig($name, $optParams = [])
|
---|
46 | {
|
---|
47 | $params = ['name' => $name];
|
---|
48 | $params = array_merge($params, $optParams);
|
---|
49 | return $this->call('retrieveConfig', [$params], GoogleCloudDatacatalogV1OrganizationConfig::class);
|
---|
50 | }
|
---|
51 | /**
|
---|
52 | * Retrieves the effective configuration related to the migration from Data
|
---|
53 | * Catalog to Dataplex for a specific organization or project. If there is no
|
---|
54 | * specific configuration set for the resource, the setting is checked
|
---|
55 | * hierarchicahlly through the ancestors of the resource, starting from the
|
---|
56 | * resource itself. (locations.retrieveEffectiveConfig)
|
---|
57 | *
|
---|
58 | * @param string $name Required. The resource whose effective config is being
|
---|
59 | * retrieved.
|
---|
60 | * @param array $optParams Optional parameters.
|
---|
61 | * @return GoogleCloudDatacatalogV1MigrationConfig
|
---|
62 | * @throws \Google\Service\Exception
|
---|
63 | */
|
---|
64 | public function retrieveEffectiveConfig($name, $optParams = [])
|
---|
65 | {
|
---|
66 | $params = ['name' => $name];
|
---|
67 | $params = array_merge($params, $optParams);
|
---|
68 | return $this->call('retrieveEffectiveConfig', [$params], GoogleCloudDatacatalogV1MigrationConfig::class);
|
---|
69 | }
|
---|
70 | /**
|
---|
71 | * Sets the configuration related to the migration to Dataplex for an
|
---|
72 | * organization or project. (locations.setConfig)
|
---|
73 | *
|
---|
74 | * @param string $name Required. The organization or project whose config is
|
---|
75 | * being specified.
|
---|
76 | * @param GoogleCloudDatacatalogV1SetConfigRequest $postBody
|
---|
77 | * @param array $optParams Optional parameters.
|
---|
78 | * @return GoogleCloudDatacatalogV1MigrationConfig
|
---|
79 | * @throws \Google\Service\Exception
|
---|
80 | */
|
---|
81 | public function setConfig($name, GoogleCloudDatacatalogV1SetConfigRequest $postBody, $optParams = [])
|
---|
82 | {
|
---|
83 | $params = ['name' => $name, 'postBody' => $postBody];
|
---|
84 | $params = array_merge($params, $optParams);
|
---|
85 | return $this->call('setConfig', [$params], GoogleCloudDatacatalogV1MigrationConfig::class);
|
---|
86 | }
|
---|
87 | }
|
---|
88 |
|
---|
89 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
90 | class_alias(OrganizationsLocations::class, 'Google_Service_DataCatalog_Resource_OrganizationsLocations');
|
---|