Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

Commit

Permalink
Integrate Python GAPIC Microgenerator in googleapis. This PR uses usi…
Browse files Browse the repository at this point in the history
…ng documentai as an example. Depends on googleapis/gapic-generator-python#402

PiperOrigin-RevId: 309824146

Source-Author: Google APIs <noreply@google.com>
Source-Date: Mon May 4 15:06:44 2020 -0700
Source-Repo: googleapis/googleapis
Source-Sha: e0f9d9e1f9de890db765be46f45ca8490723e3eb
Source-Link: googleapis/googleapis@e0f9d9e
  • Loading branch information
yoshi-automation committed Jun 24, 2020
1 parent 01304e7 commit d93e8ef
Show file tree
Hide file tree
Showing 23 changed files with 1,791 additions and 1,823 deletions.
36 changes: 18 additions & 18 deletions google/cloud/tasks_v2/gapic/cloud_tasks_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ def list_queues(
Sample filter "state: PAUSED".
Note that using filters might cause fewer queues than the requested
page\_size to be returned.
page_size to be returned.
page_size (int): The maximum number of resources contained in the
underlying API response. If page streaming is performed per-
resource, this parameter does not affect the return value. If page
Expand Down Expand Up @@ -920,8 +920,8 @@ def get_iam_policy(
metadata=None,
):
"""
Gets the access control policy for a ``Queue``. Returns an empty policy
if the resource exists and does not have a policy set.
Gets the access control policy for a ``Queue``. Returns an empty
policy if the resource exists and does not have a policy set.
Authorization requires the following `Google
IAM <https://cloud.google.com/iam>`__ permission on the specified
Expand Down Expand Up @@ -1006,8 +1006,8 @@ def set_iam_policy(
metadata=None,
):
"""
Sets the access control policy for a ``Queue``. Replaces any existing
policy.
Sets the access control policy for a ``Queue``. Replaces any
existing policy.
Note: The Cloud Console does not check queue-level IAM permissions yet.
Project-level permissions are required to use the Cloud Console.
Expand Down Expand Up @@ -1098,9 +1098,9 @@ def test_iam_permissions(
metadata=None,
):
"""
Returns permissions that a caller has on a ``Queue``. If the resource
does not exist, this will return an empty set of permissions, not a
``NOT_FOUND`` error.
Returns permissions that a caller has on a ``Queue``. If the
resource does not exist, this will return an empty set of permissions,
not a ``NOT_FOUND`` error.
Note: This operation is designed to be used for building
permission-aware UIs and command-line tools, not for authorization
Expand All @@ -1122,8 +1122,8 @@ def test_iam_permissions(
Args:
resource (str): REQUIRED: The resource for which the policy detail is being requested.
See the operation documentation for the appropriate value for this field.
permissions (list[str]): The set of permissions to check for the ``resource``. Permissions with
wildcards (such as '*' or 'storage.*') are not allowed. For more
permissions (list[str]): The set of permissions to check for the ``resource``. Permissions
with wildcards (such as '*' or 'storage.*') are not allowed. For more
information see `IAM
Overview <https://cloud.google.com/iam/docs/overview#permissions>`__.
retry (Optional[google.api_core.retry.Retry]): A retry object used
Expand Down Expand Up @@ -1219,10 +1219,10 @@ def list_tasks(
Args:
parent (str): Required. The queue name. For example:
``projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID``
response_view (~google.cloud.tasks_v2.enums.Task.View): The response\_view specifies which subset of the ``Task`` will be
response_view (~google.cloud.tasks_v2.enums.Task.View): The response_view specifies which subset of the ``Task`` will be
returned.
By default response\_view is ``BASIC``; not all information is retrieved
By default response_view is ``BASIC``; not all information is retrieved
by default because some data, such as payloads, might be desirable to
return only when needed because of its large size or because of the
sensitivity of data that it contains.
Expand Down Expand Up @@ -1322,10 +1322,10 @@ def get_task(
Args:
name (str): Required. The task name. For example:
``projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID``
response_view (~google.cloud.tasks_v2.enums.Task.View): The response\_view specifies which subset of the ``Task`` will be
response_view (~google.cloud.tasks_v2.enums.Task.View): The response_view specifies which subset of the ``Task`` will be
returned.
By default response\_view is ``BASIC``; not all information is retrieved
By default response_view is ``BASIC``; not all information is retrieved
by default because some data, such as payloads, might be desirable to
return only when needed because of its large size or because of the
sensitivity of data that it contains.
Expand Down Expand Up @@ -1447,10 +1447,10 @@ def create_task(
If a dict is provided, it must be of the same form as the protobuf
message :class:`~google.cloud.tasks_v2.types.Task`
response_view (~google.cloud.tasks_v2.enums.Task.View): The response\_view specifies which subset of the ``Task`` will be
response_view (~google.cloud.tasks_v2.enums.Task.View): The response_view specifies which subset of the ``Task`` will be
returned.
By default response\_view is ``BASIC``; not all information is retrieved
By default response_view is ``BASIC``; not all information is retrieved
by default because some data, such as payloads, might be desirable to
return only when needed because of its large size or because of the
sensitivity of data that it contains.
Expand Down Expand Up @@ -1622,10 +1622,10 @@ def run_task(
Args:
name (str): Required. The task name. For example:
``projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID``
response_view (~google.cloud.tasks_v2.enums.Task.View): The response\_view specifies which subset of the ``Task`` will be
response_view (~google.cloud.tasks_v2.enums.Task.View): The response_view specifies which subset of the ``Task`` will be
returned.
By default response\_view is ``BASIC``; not all information is retrieved
By default response_view is ``BASIC``; not all information is retrieved
by default because some data, such as payloads, might be desirable to
return only when needed because of its large size or because of the
sensitivity of data that it contains.
Expand Down
4 changes: 2 additions & 2 deletions google/cloud/tasks_v2/gapic/enums.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,8 @@ class View(enum.IntEnum):
Attributes:
VIEW_UNSPECIFIED (int): Unspecified. Defaults to BASIC.
BASIC (int): The basic view omits fields which can be large or can contain sensitive
data.
BASIC (int): The basic view omits fields which can be large or can contain
sensitive data.
This view does not include the ``body in AppEngineHttpRequest``. Bodies
are desirable to return only when needed, because they can be large and
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -267,8 +267,8 @@ def resume_queue(self):
def get_iam_policy(self):
"""Return the gRPC stub for :meth:`CloudTasksClient.get_iam_policy`.
Gets the access control policy for a ``Queue``. Returns an empty policy
if the resource exists and does not have a policy set.
Gets the access control policy for a ``Queue``. Returns an empty
policy if the resource exists and does not have a policy set.
Authorization requires the following `Google
IAM <https://cloud.google.com/iam>`__ permission on the specified
Expand All @@ -287,8 +287,8 @@ def get_iam_policy(self):
def set_iam_policy(self):
"""Return the gRPC stub for :meth:`CloudTasksClient.set_iam_policy`.
Sets the access control policy for a ``Queue``. Replaces any existing
policy.
Sets the access control policy for a ``Queue``. Replaces any
existing policy.
Note: The Cloud Console does not check queue-level IAM permissions yet.
Project-level permissions are required to use the Cloud Console.
Expand All @@ -310,9 +310,9 @@ def set_iam_policy(self):
def test_iam_permissions(self):
"""Return the gRPC stub for :meth:`CloudTasksClient.test_iam_permissions`.
Returns permissions that a caller has on a ``Queue``. If the resource
does not exist, this will return an empty set of permissions, not a
``NOT_FOUND`` error.
Returns permissions that a caller has on a ``Queue``. If the
resource does not exist, this will return an empty set of permissions,
not a ``NOT_FOUND`` error.
Note: This operation is designed to be used for building
permission-aware UIs and command-line tools, not for authorization
Expand Down
Loading

0 comments on commit d93e8ef

Please sign in to comment.