Skip to content

Commit

Permalink
revert artifact registry changes for this changeset
Browse files Browse the repository at this point in the history
  • Loading branch information
David Supplee committed Jan 9, 2023
1 parent eecf3b2 commit 34980c2
Show file tree
Hide file tree
Showing 7 changed files with 0 additions and 391 deletions.

This file was deleted.

This file was deleted.

128 changes: 0 additions & 128 deletions ArtifactRegistry/src/V1beta2/Gapic/ArtifactRegistryGapicClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
namespace Google\Cloud\ArtifactRegistry\V1beta2\Gapic;

use Google\ApiCore\ApiException;
use Google\ApiCore\Call;
use Google\ApiCore\CredentialsWrapper;
use Google\ApiCore\GapicClientTrait;
use Google\ApiCore\LongRunning\OperationsClient;
Expand Down Expand Up @@ -79,10 +78,6 @@
use Google\Cloud\Iam\V1\SetIamPolicyRequest;
use Google\Cloud\Iam\V1\TestIamPermissionsRequest;
use Google\Cloud\Iam\V1\TestIamPermissionsResponse;
use Google\Cloud\Location\GetLocationRequest;
use Google\Cloud\Location\ListLocationsRequest;
use Google\Cloud\Location\ListLocationsResponse;
use Google\Cloud\Location\Location;
use Google\LongRunning\Operation;
use Google\Protobuf\FieldMask;
use Google\Protobuf\GPBEmpty;
Expand Down Expand Up @@ -1955,127 +1950,4 @@ public function updateTag(array $optionalArgs = [])
$optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader();
return $this->startCall('UpdateTag', Tag::class, $optionalArgs, $request)->wait();
}

/**
* Gets information about a location.
*
* Sample code:
* ```
* $artifactRegistryClient = new ArtifactRegistryClient();
* try {
* $response = $artifactRegistryClient->getLocation();
* } finally {
* $artifactRegistryClient->close();
* }
* ```
*
* @param array $optionalArgs {
* Optional.
*
* @type string $name
* Resource name for the location.
* @type RetrySettings|array $retrySettings
* Retry settings to use for this call. Can be a {@see RetrySettings} object, or an
* associative array of retry settings parameters. See the documentation on
* {@see RetrySettings} for example usage.
* }
*
* @return \Google\Cloud\Location\Location
*
* @throws ApiException if the remote call fails
*
* @experimental
*/
public function getLocation(array $optionalArgs = [])
{
$request = new GetLocationRequest();
$requestParamHeaders = [];
if (isset($optionalArgs['name'])) {
$request->setName($optionalArgs['name']);
$requestParamHeaders['name'] = $optionalArgs['name'];
}

$requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders);
$optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader();
return $this->startCall('GetLocation', Location::class, $optionalArgs, $request, Call::UNARY_CALL, 'google.cloud.location.Locations')->wait();
}

/**
* Lists information about the supported locations for this service.
*
* Sample code:
* ```
* $artifactRegistryClient = new ArtifactRegistryClient();
* try {
* // Iterate over pages of elements
* $pagedResponse = $artifactRegistryClient->listLocations();
* foreach ($pagedResponse->iteratePages() as $page) {
* foreach ($page as $element) {
* // doSomethingWith($element);
* }
* }
* // Alternatively:
* // Iterate through all elements
* $pagedResponse = $artifactRegistryClient->listLocations();
* foreach ($pagedResponse->iterateAllElements() as $element) {
* // doSomethingWith($element);
* }
* } finally {
* $artifactRegistryClient->close();
* }
* ```
*
* @param array $optionalArgs {
* Optional.
*
* @type string $name
* The resource that owns the locations collection, if applicable.
* @type string $filter
* The standard list filter.
* @type int $pageSize
* The maximum number of resources contained in the underlying API
* response. The API may return fewer values in a page, even if
* there are additional values to be retrieved.
* @type string $pageToken
* A page token is used to specify a page of values to be returned.
* If no page token is specified (the default), the first page
* of values will be returned. Any page token used here must have
* been generated by a previous call to the API.
* @type RetrySettings|array $retrySettings
* Retry settings to use for this call. Can be a {@see RetrySettings} object, or an
* associative array of retry settings parameters. See the documentation on
* {@see RetrySettings} for example usage.
* }
*
* @return \Google\ApiCore\PagedListResponse
*
* @throws ApiException if the remote call fails
*
* @experimental
*/
public function listLocations(array $optionalArgs = [])
{
$request = new ListLocationsRequest();
$requestParamHeaders = [];
if (isset($optionalArgs['name'])) {
$request->setName($optionalArgs['name']);
$requestParamHeaders['name'] = $optionalArgs['name'];
}

if (isset($optionalArgs['filter'])) {
$request->setFilter($optionalArgs['filter']);
}

if (isset($optionalArgs['pageSize'])) {
$request->setPageSize($optionalArgs['pageSize']);
}

if (isset($optionalArgs['pageToken'])) {
$request->setPageToken($optionalArgs['pageToken']);
}

$requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders);
$optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader();
return $this->getPagedListResponse('ListLocations', $optionalArgs, ListLocationsResponse::class, $request, 'google.cloud.location.Locations');
}
}
10 changes: 0 additions & 10 deletions ArtifactRegistry/src/V1beta2/gapic_metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -134,16 +134,6 @@
"methods": [
"updateTag"
]
},
"GetLocation": {
"methods": [
"getLocation"
]
},
"ListLocations": {
"methods": [
"listLocations"
]
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,16 +162,6 @@
"timeout_millis": 30000,
"retry_codes_name": "no_retry_1_codes",
"retry_params_name": "no_retry_1_params"
},
"GetLocation": {
"timeout_millis": 60000,
"retry_codes_name": "no_retry_codes",
"retry_params_name": "no_retry_params"
},
"ListLocations": {
"timeout_millis": 60000,
"retry_codes_name": "no_retry_codes",
"retry_params_name": "no_retry_params"
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,16 +113,6 @@
'resourcesGetMethod' => 'getVersions',
],
],
'ListLocations' => [
'pageStreaming' => [
'requestPageTokenGetMethod' => 'getPageToken',
'requestPageTokenSetMethod' => 'setPageToken',
'requestPageSizeGetMethod' => 'getPageSize',
'requestPageSizeSetMethod' => 'setPageSize',
'responsePageTokenGetMethod' => 'getNextPageToken',
'resourcesGetMethod' => 'getLocations',
],
],
],
],
];
Loading

0 comments on commit 34980c2

Please sign in to comment.