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\ChecksService\Resource;
|
---|
19 |
|
---|
20 | use Google\Service\ChecksService\GoogleChecksReportV1alphaListReportsResponse;
|
---|
21 | use Google\Service\ChecksService\GoogleChecksReportV1alphaReport;
|
---|
22 |
|
---|
23 | /**
|
---|
24 | * The "reports" collection of methods.
|
---|
25 | * Typical usage is:
|
---|
26 | * <code>
|
---|
27 | * $checksService = new Google\Service\ChecksService(...);
|
---|
28 | * $reports = $checksService->accounts_apps_reports;
|
---|
29 | * </code>
|
---|
30 | */
|
---|
31 | class AccountsAppsReports extends \Google\Service\Resource
|
---|
32 | {
|
---|
33 | /**
|
---|
34 | * Gets a report. By default, only the name and results_uri fields are returned.
|
---|
35 | * You can include other fields by listing them in the `fields` URL query
|
---|
36 | * parameter. For example, `?fields=name,checks` will return the name and checks
|
---|
37 | * fields. (reports.get)
|
---|
38 | *
|
---|
39 | * @param string $name Required. Resource name of the report. Example:
|
---|
40 | * `accounts/123/apps/456/reports/789`
|
---|
41 | * @param array $optParams Optional parameters.
|
---|
42 | *
|
---|
43 | * @opt_param string checksFilter Optional. An
|
---|
44 | * [AIP-160](https://google.aip.dev/160) filter string to filter checks within
|
---|
45 | * the report. Only checks that match the filter string are included in the
|
---|
46 | * response. Example: `state = FAILED`
|
---|
47 | * @return GoogleChecksReportV1alphaReport
|
---|
48 | * @throws \Google\Service\Exception
|
---|
49 | */
|
---|
50 | public function get($name, $optParams = [])
|
---|
51 | {
|
---|
52 | $params = ['name' => $name];
|
---|
53 | $params = array_merge($params, $optParams);
|
---|
54 | return $this->call('get', [$params], GoogleChecksReportV1alphaReport::class);
|
---|
55 | }
|
---|
56 | /**
|
---|
57 | * Lists reports for the specified app. By default, only the name and
|
---|
58 | * results_uri fields are returned. You can include other fields by listing them
|
---|
59 | * in the `fields` URL query parameter. For example,
|
---|
60 | * `?fields=reports(name,checks)` will return the name and checks fields.
|
---|
61 | * (reports.listAccountsAppsReports)
|
---|
62 | *
|
---|
63 | * @param string $parent Required. Resource name of the app. Example:
|
---|
64 | * `accounts/123/apps/456`
|
---|
65 | * @param array $optParams Optional parameters.
|
---|
66 | *
|
---|
67 | * @opt_param string checksFilter Optional. An
|
---|
68 | * [AIP-160](https://google.aip.dev/160) filter string to filter checks within
|
---|
69 | * reports. Only checks that match the filter string are included in the
|
---|
70 | * response. Example: `state = FAILED`
|
---|
71 | * @opt_param string filter Optional. An [AIP-160](https://google.aip.dev/160)
|
---|
72 | * filter string to filter reports. Example: `appBundle.releaseType =
|
---|
73 | * PRE_RELEASE`
|
---|
74 | * @opt_param int pageSize Optional. The maximum number of reports to return. If
|
---|
75 | * unspecified, at most 10 reports will be returned. The maximum value is 50;
|
---|
76 | * values above 50 will be coerced to 50.
|
---|
77 | * @opt_param string pageToken Optional. A page token received from a previous
|
---|
78 | * `ListReports` call. Provide this to retrieve the subsequent page. When
|
---|
79 | * paginating, all other parameters provided to `ListReports` must match the
|
---|
80 | * call that provided the page token.
|
---|
81 | * @return GoogleChecksReportV1alphaListReportsResponse
|
---|
82 | * @throws \Google\Service\Exception
|
---|
83 | */
|
---|
84 | public function listAccountsAppsReports($parent, $optParams = [])
|
---|
85 | {
|
---|
86 | $params = ['parent' => $parent];
|
---|
87 | $params = array_merge($params, $optParams);
|
---|
88 | return $this->call('list', [$params], GoogleChecksReportV1alphaListReportsResponse::class);
|
---|
89 | }
|
---|
90 | }
|
---|
91 |
|
---|
92 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
93 | class_alias(AccountsAppsReports::class, 'Google_Service_ChecksService_Resource_AccountsAppsReports');
|
---|