[e3d4e0a] | 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\FirebaseAppDistribution\Resource;
|
---|
| 19 |
|
---|
| 20 | use Google\Service\FirebaseAppDistribution\GoogleFirebaseAppdistroV1BatchAddTestersRequest;
|
---|
| 21 | use Google\Service\FirebaseAppDistribution\GoogleFirebaseAppdistroV1BatchAddTestersResponse;
|
---|
| 22 | use Google\Service\FirebaseAppDistribution\GoogleFirebaseAppdistroV1BatchRemoveTestersRequest;
|
---|
| 23 | use Google\Service\FirebaseAppDistribution\GoogleFirebaseAppdistroV1BatchRemoveTestersResponse;
|
---|
| 24 | use Google\Service\FirebaseAppDistribution\GoogleFirebaseAppdistroV1ListTestersResponse;
|
---|
| 25 | use Google\Service\FirebaseAppDistribution\GoogleFirebaseAppdistroV1Tester;
|
---|
| 26 |
|
---|
| 27 | /**
|
---|
| 28 | * The "testers" collection of methods.
|
---|
| 29 | * Typical usage is:
|
---|
| 30 | * <code>
|
---|
| 31 | * $firebaseappdistributionService = new Google\Service\FirebaseAppDistribution(...);
|
---|
| 32 | * $testers = $firebaseappdistributionService->projects_testers;
|
---|
| 33 | * </code>
|
---|
| 34 | */
|
---|
| 35 | class ProjectsTesters extends \Google\Service\Resource
|
---|
| 36 | {
|
---|
| 37 | /**
|
---|
| 38 | * Batch adds testers. This call adds testers for the specified emails if they
|
---|
| 39 | * don't already exist. Returns all testers specified in the request, including
|
---|
| 40 | * newly created and previously existing testers. This action is idempotent.
|
---|
| 41 | * (testers.batchAdd)
|
---|
| 42 | *
|
---|
| 43 | * @param string $project Required. The name of the project resource. Format:
|
---|
| 44 | * `projects/{project_number}`
|
---|
| 45 | * @param GoogleFirebaseAppdistroV1BatchAddTestersRequest $postBody
|
---|
| 46 | * @param array $optParams Optional parameters.
|
---|
| 47 | * @return GoogleFirebaseAppdistroV1BatchAddTestersResponse
|
---|
| 48 | * @throws \Google\Service\Exception
|
---|
| 49 | */
|
---|
| 50 | public function batchAdd($project, GoogleFirebaseAppdistroV1BatchAddTestersRequest $postBody, $optParams = [])
|
---|
| 51 | {
|
---|
| 52 | $params = ['project' => $project, 'postBody' => $postBody];
|
---|
| 53 | $params = array_merge($params, $optParams);
|
---|
| 54 | return $this->call('batchAdd', [$params], GoogleFirebaseAppdistroV1BatchAddTestersResponse::class);
|
---|
| 55 | }
|
---|
| 56 | /**
|
---|
| 57 | * Batch removes testers. If found, this call deletes testers for the specified
|
---|
| 58 | * emails. Returns all deleted testers. (testers.batchRemove)
|
---|
| 59 | *
|
---|
| 60 | * @param string $project Required. The name of the project resource. Format:
|
---|
| 61 | * `projects/{project_number}`
|
---|
| 62 | * @param GoogleFirebaseAppdistroV1BatchRemoveTestersRequest $postBody
|
---|
| 63 | * @param array $optParams Optional parameters.
|
---|
| 64 | * @return GoogleFirebaseAppdistroV1BatchRemoveTestersResponse
|
---|
| 65 | * @throws \Google\Service\Exception
|
---|
| 66 | */
|
---|
| 67 | public function batchRemove($project, GoogleFirebaseAppdistroV1BatchRemoveTestersRequest $postBody, $optParams = [])
|
---|
| 68 | {
|
---|
| 69 | $params = ['project' => $project, 'postBody' => $postBody];
|
---|
| 70 | $params = array_merge($params, $optParams);
|
---|
| 71 | return $this->call('batchRemove', [$params], GoogleFirebaseAppdistroV1BatchRemoveTestersResponse::class);
|
---|
| 72 | }
|
---|
| 73 | /**
|
---|
| 74 | * Lists testers and their resource ids. (testers.listProjectsTesters)
|
---|
| 75 | *
|
---|
| 76 | * @param string $parent Required. The name of the project resource, which is
|
---|
| 77 | * the parent of the tester resources. Format: `projects/{project_number}`
|
---|
| 78 | * @param array $optParams Optional parameters.
|
---|
| 79 | *
|
---|
| 80 | * @opt_param string filter Optional. The expression to filter testers listed in
|
---|
| 81 | * the response. To learn more about filtering, refer to [Google's AIP-160
|
---|
| 82 | * standard](http://aip.dev/160). Supported fields: - `name` - `displayName` -
|
---|
| 83 | * `groups` Example: - `name = "projects/-/testers@example.com"` - `displayName
|
---|
| 84 | * = "Joe Sixpack"` - `groups = "projects/groups/qa-team"`
|
---|
| 85 | * @opt_param int pageSize Optional. The maximum number of testers to return.
|
---|
| 86 | * The service may return fewer than this value. The valid range is [1-1000]; If
|
---|
| 87 | * unspecified (0), at most 10 testers are returned. Values above 1000 are
|
---|
| 88 | * coerced to 1000.
|
---|
| 89 | * @opt_param string pageToken Optional. A page token, received from a previous
|
---|
| 90 | * `ListTesters` call. Provide this to retrieve the subsequent page. When
|
---|
| 91 | * paginating, all other parameters provided to `ListTesters` must match the
|
---|
| 92 | * call that provided the page token.
|
---|
| 93 | * @return GoogleFirebaseAppdistroV1ListTestersResponse
|
---|
| 94 | * @throws \Google\Service\Exception
|
---|
| 95 | */
|
---|
| 96 | public function listProjectsTesters($parent, $optParams = [])
|
---|
| 97 | {
|
---|
| 98 | $params = ['parent' => $parent];
|
---|
| 99 | $params = array_merge($params, $optParams);
|
---|
| 100 | return $this->call('list', [$params], GoogleFirebaseAppdistroV1ListTestersResponse::class);
|
---|
| 101 | }
|
---|
| 102 | /**
|
---|
| 103 | * Update a tester. If the testers joins a group they gain access to all
|
---|
| 104 | * releases that the group has access to. (testers.patch)
|
---|
| 105 | *
|
---|
| 106 | * @param string $name The name of the tester resource. Format:
|
---|
| 107 | * `projects/{project_number}/testers/{email_address}`
|
---|
| 108 | * @param GoogleFirebaseAppdistroV1Tester $postBody
|
---|
| 109 | * @param array $optParams Optional parameters.
|
---|
| 110 | *
|
---|
| 111 | * @opt_param string updateMask The list of fields to update.
|
---|
| 112 | * @return GoogleFirebaseAppdistroV1Tester
|
---|
| 113 | * @throws \Google\Service\Exception
|
---|
| 114 | */
|
---|
| 115 | public function patch($name, GoogleFirebaseAppdistroV1Tester $postBody, $optParams = [])
|
---|
| 116 | {
|
---|
| 117 | $params = ['name' => $name, 'postBody' => $postBody];
|
---|
| 118 | $params = array_merge($params, $optParams);
|
---|
| 119 | return $this->call('patch', [$params], GoogleFirebaseAppdistroV1Tester::class);
|
---|
| 120 | }
|
---|
| 121 | }
|
---|
| 122 |
|
---|
| 123 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
| 124 | class_alias(ProjectsTesters::class, 'Google_Service_FirebaseAppDistribution_Resource_ProjectsTesters');
|
---|