class ProjectsLocationsBucketsViews extends Resource (View source)

The "views" collection of methods.

Typical usage is:

 $loggingService = new Google\Service\Logging(...);
 $views = $loggingService->projects_locations_buckets_views;

Methods

create(string $parent, LogView $postBody, array $optParams = [])

Creates a view over log entries in a log bucket. A bucket may contain a maximum of 30 views. (views.create)

delete(string $name, array $optParams = [])

Deletes a view on a log bucket. If an UNAVAILABLE error is returned, this indicates that system is not in a state where it can delete the view. If this occurs, please try again in a few minutes. (views.delete)

get(string $name, array $optParams = [])

Gets a view on a log bucket. (views.get)

getIamPolicy(string $resource, GetIamPolicyRequest $postBody, array $optParams = [])

Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set. (views.getIamPolicy)

listProjectsLocationsBucketsViews(string $parent, array $optParams = [])

Lists views on a log bucket. (views.listProjectsLocationsBucketsViews)

patch(string $name, LogView $postBody, array $optParams = [])

Updates a view on a log bucket. This method replaces the value of the filter field from the existing view with the corresponding value from the new view.

setIamPolicy(string $resource, SetIamPolicyRequest $postBody, array $optParams = [])

Sets the access control policy on the specified resource. Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors. (views.setIamPolicy)

testIamPermissions(string $resource, TestIamPermissionsRequest $postBody, array $optParams = [])

Returns permissions that a caller has on the specified resource. 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 checking.

Details

LogView create(string $parent, LogView $postBody, array $optParams = [])

Creates a view over log entries in a log bucket. A bucket may contain a maximum of 30 views. (views.create)

Parameters

string $parent

Required. The bucket in which to create the view "projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" For example:"projects/my-project/locations/global/buckets/my-bucket"

LogView $postBody
array $optParams

Optional parameters.

Return Value

LogView

Exceptions

Exception

LoggingEmpty delete(string $name, array $optParams = [])

Deletes a view on a log bucket. If an UNAVAILABLE error is returned, this indicates that system is not in a state where it can delete the view. If this occurs, please try again in a few minutes. (views.delete)

Parameters

string $name

Required. The full resource name of the view to delete: " projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW _ID]" For example:"projects/my-project/locations/global/buckets/my- bucket/views/my-view"

array $optParams

Optional parameters.

Return Value

LoggingEmpty

Exceptions

Exception

LogView get(string $name, array $optParams = [])

Gets a view on a log bucket. (views.get)

Parameters

string $name

Required. The resource name of the policy: "projects/[PRO JECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]" For example:"projects/my-project/locations/global/buckets/my-bucket/views/my- view"

array $optParams

Optional parameters.

Return Value

LogView

Exceptions

Exception

Policy getIamPolicy(string $resource, GetIamPolicyRequest $postBody, array $optParams = [])

Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set. (views.getIamPolicy)

Parameters

string $resource

REQUIRED: The resource for which the policy is being requested. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

GetIamPolicyRequest $postBody
array $optParams

Optional parameters.

Return Value

Policy

Exceptions

Exception

ListViewsResponse listProjectsLocationsBucketsViews(string $parent, array $optParams = [])

Lists views on a log bucket. (views.listProjectsLocationsBucketsViews)

Parameters

string $parent

Required. The bucket whose views are to be listed: "projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]"

array $optParams

Optional parameters.

Return Value

ListViewsResponse

Exceptions

Exception

LogView patch(string $name, LogView $postBody, array $optParams = [])

Updates a view on a log bucket. This method replaces the value of the filter field from the existing view with the corresponding value from the new view.

If an UNAVAILABLE error is returned, this indicates that system is not in a state where it can update the view. If this occurs, please try again in a few minutes. (views.patch)

Parameters

string $name

Required. The full resource name of the view to update "p rojects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKETID]/views/[VIEW ID]" For example:"projects/my-project/locations/global/buckets/my- bucket/views/my-view"

LogView $postBody
array $optParams

Optional parameters.

Return Value

LogView

Exceptions

Exception

Policy setIamPolicy(string $resource, SetIamPolicyRequest $postBody, array $optParams = [])

Sets the access control policy on the specified resource. Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors. (views.setIamPolicy)

Parameters

string $resource

REQUIRED: The resource for which the policy is being specified. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

SetIamPolicyRequest $postBody
array $optParams

Optional parameters.

Return Value

Policy

Exceptions

Exception

TestIamPermissionsResponse testIamPermissions(string $resource, TestIamPermissionsRequest $postBody, array $optParams = [])

Returns permissions that a caller has on the specified resource. 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 checking.

This operation may "fail open" without warning. (views.testIamPermissions)

Parameters

string $resource

REQUIRED: The resource for which the policy detail is being requested. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

TestIamPermissionsRequest $postBody
array $optParams

Optional parameters.

Return Value

TestIamPermissionsResponse

Exceptions

Exception