[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\CloudHealthcare\Resource;
|
---|
| 19 |
|
---|
| 20 | use Google\Service\CloudHealthcare\ConsentArtifact;
|
---|
| 21 | use Google\Service\CloudHealthcare\HealthcareEmpty;
|
---|
| 22 | use Google\Service\CloudHealthcare\ListConsentArtifactsResponse;
|
---|
| 23 |
|
---|
| 24 | /**
|
---|
| 25 | * The "consentArtifacts" collection of methods.
|
---|
| 26 | * Typical usage is:
|
---|
| 27 | * <code>
|
---|
| 28 | * $healthcareService = new Google\Service\CloudHealthcare(...);
|
---|
| 29 | * $consentArtifacts = $healthcareService->projects_locations_datasets_consentStores_consentArtifacts;
|
---|
| 30 | * </code>
|
---|
| 31 | */
|
---|
| 32 | class ProjectsLocationsDatasetsConsentStoresConsentArtifacts extends \Google\Service\Resource
|
---|
| 33 | {
|
---|
| 34 | /**
|
---|
| 35 | * Creates a new Consent artifact in the parent consent store.
|
---|
| 36 | * (consentArtifacts.create)
|
---|
| 37 | *
|
---|
| 38 | * @param string $parent Required. The name of the consent store this Consent
|
---|
| 39 | * artifact belongs to.
|
---|
| 40 | * @param ConsentArtifact $postBody
|
---|
| 41 | * @param array $optParams Optional parameters.
|
---|
| 42 | * @return ConsentArtifact
|
---|
| 43 | * @throws \Google\Service\Exception
|
---|
| 44 | */
|
---|
| 45 | public function create($parent, ConsentArtifact $postBody, $optParams = [])
|
---|
| 46 | {
|
---|
| 47 | $params = ['parent' => $parent, 'postBody' => $postBody];
|
---|
| 48 | $params = array_merge($params, $optParams);
|
---|
| 49 | return $this->call('create', [$params], ConsentArtifact::class);
|
---|
| 50 | }
|
---|
| 51 | /**
|
---|
| 52 | * Deletes the specified Consent artifact. Fails if the artifact is referenced
|
---|
| 53 | * by the latest revision of any Consent. (consentArtifacts.delete)
|
---|
| 54 | *
|
---|
| 55 | * @param string $name Required. The resource name of the Consent artifact to
|
---|
| 56 | * delete. To preserve referential integrity, Consent artifacts referenced by
|
---|
| 57 | * the latest revision of a Consent cannot be deleted.
|
---|
| 58 | * @param array $optParams Optional parameters.
|
---|
| 59 | * @return HealthcareEmpty
|
---|
| 60 | * @throws \Google\Service\Exception
|
---|
| 61 | */
|
---|
| 62 | public function delete($name, $optParams = [])
|
---|
| 63 | {
|
---|
| 64 | $params = ['name' => $name];
|
---|
| 65 | $params = array_merge($params, $optParams);
|
---|
| 66 | return $this->call('delete', [$params], HealthcareEmpty::class);
|
---|
| 67 | }
|
---|
| 68 | /**
|
---|
| 69 | * Gets the specified Consent artifact. (consentArtifacts.get)
|
---|
| 70 | *
|
---|
| 71 | * @param string $name Required. The resource name of the Consent artifact to
|
---|
| 72 | * retrieve.
|
---|
| 73 | * @param array $optParams Optional parameters.
|
---|
| 74 | * @return ConsentArtifact
|
---|
| 75 | * @throws \Google\Service\Exception
|
---|
| 76 | */
|
---|
| 77 | public function get($name, $optParams = [])
|
---|
| 78 | {
|
---|
| 79 | $params = ['name' => $name];
|
---|
| 80 | $params = array_merge($params, $optParams);
|
---|
| 81 | return $this->call('get', [$params], ConsentArtifact::class);
|
---|
| 82 | }
|
---|
| 83 | /**
|
---|
| 84 | * Lists the Consent artifacts in the specified consent store.
|
---|
| 85 | * (consentArtifacts.listProjectsLocationsDatasetsConsentStoresConsentArtifacts)
|
---|
| 86 | *
|
---|
| 87 | * @param string $parent Required. Name of the consent store to retrieve consent
|
---|
| 88 | * artifacts from.
|
---|
| 89 | * @param array $optParams Optional parameters.
|
---|
| 90 | *
|
---|
| 91 | * @opt_param string filter Optional. Restricts the artifacts returned to those
|
---|
| 92 | * matching a filter. The following syntax is available: * A string field value
|
---|
| 93 | * can be written as text inside quotation marks, for example `"query text"`.
|
---|
| 94 | * The only valid relational operation for text fields is equality (`=`), where
|
---|
| 95 | * text is searched within the field, rather than having the field be equal to
|
---|
| 96 | * the text. For example, `"Comment = great"` returns messages with `great` in
|
---|
| 97 | * the comment field. * A number field value can be written as an integer, a
|
---|
| 98 | * decimal, or an exponential. The valid relational operators for number fields
|
---|
| 99 | * are the equality operator (`=`), along with the less than/greater than
|
---|
| 100 | * operators (`<`, `<=`, `>`, `>=`). Note that there is no inequality (`!=`)
|
---|
| 101 | * operator. You can prepend the `NOT` operator to an expression to negate it. *
|
---|
| 102 | * A date field value must be written in `yyyy-mm-dd` form. Fields with date and
|
---|
| 103 | * time use the RFC3339 time format. Leading zeros are required for one-digit
|
---|
| 104 | * months and days. The valid relational operators for date fields are the
|
---|
| 105 | * equality operator (`=`) , along with the less than/greater than operators
|
---|
| 106 | * (`<`, `<=`, `>`, `>=`). Note that there is no inequality (`!=`) operator. You
|
---|
| 107 | * can prepend the `NOT` operator to an expression to negate it. * Multiple
|
---|
| 108 | * field query expressions can be combined in one query by adding `AND` or `OR`
|
---|
| 109 | * operators between the expressions. If a boolean operator appears within a
|
---|
| 110 | * quoted string, it is not treated as special, it's just another part of the
|
---|
| 111 | * character string to be matched. You can prepend the `NOT` operator to an
|
---|
| 112 | * expression to negate it. The fields available for filtering are: - user_id.
|
---|
| 113 | * For example, `filter=user_id=\"user123\"`. - consent_content_version -
|
---|
| 114 | * metadata. For example, `filter=Metadata(\"testkey\")=\"value\"` or
|
---|
| 115 | * `filter=HasMetadata(\"testkey\")`.
|
---|
| 116 | * @opt_param int pageSize Optional. Limit on the number of consent artifacts to
|
---|
| 117 | * return in a single response. If not specified, 100 is used. May not be larger
|
---|
| 118 | * than 1000.
|
---|
| 119 | * @opt_param string pageToken Optional. The next_page_token value returned from
|
---|
| 120 | * the previous List request, if any.
|
---|
| 121 | * @return ListConsentArtifactsResponse
|
---|
| 122 | * @throws \Google\Service\Exception
|
---|
| 123 | */
|
---|
| 124 | public function listProjectsLocationsDatasetsConsentStoresConsentArtifacts($parent, $optParams = [])
|
---|
| 125 | {
|
---|
| 126 | $params = ['parent' => $parent];
|
---|
| 127 | $params = array_merge($params, $optParams);
|
---|
| 128 | return $this->call('list', [$params], ListConsentArtifactsResponse::class);
|
---|
| 129 | }
|
---|
| 130 | }
|
---|
| 131 |
|
---|
| 132 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
| 133 | class_alias(ProjectsLocationsDatasetsConsentStoresConsentArtifacts::class, 'Google_Service_CloudHealthcare_Resource_ProjectsLocationsDatasetsConsentStoresConsentArtifacts');
|
---|