pub struct LocationMethods<'a, C>where
C: 'a,{ /* private fields */ }
Expand description
A builder providing access to all methods supported on location resources.
It is not used directly, but through the Logging
hub.
§Example
Instantiate a resource builder
extern crate hyper;
extern crate hyper_rustls;
extern crate google_logging2 as logging2;
use logging2::{Logging, FieldMask, hyper_rustls, hyper_util, yup_oauth2};
let secret: yup_oauth2::ApplicationSecret = Default::default();
let auth = yup_oauth2::InstalledFlowAuthenticator::builder(
secret,
yup_oauth2::InstalledFlowReturnMethod::HTTPRedirect,
).build().await.unwrap();
let client = hyper_util::client::legacy::Client::builder(
hyper_util::rt::TokioExecutor::new()
)
.build(
hyper_rustls::HttpsConnectorBuilder::new()
.with_native_roots()
.unwrap()
.https_or_http()
.enable_http1()
.build()
);
let mut hub = Logging::new(client, auth);
// Usually you wouldn't bind this to a variable, but keep calling *CallBuilders*
// like `buckets_create(...)`, `buckets_create_async(...)`, `buckets_delete(...)`, `buckets_get(...)`, `buckets_links_create(...)`, `buckets_links_delete(...)`, `buckets_links_get(...)`, `buckets_links_list(...)`, `buckets_list(...)`, `buckets_patch(...)`, `buckets_undelete(...)`, `buckets_update_async(...)`, `buckets_views_create(...)`, `buckets_views_delete(...)`, `buckets_views_get(...)`, `buckets_views_get_iam_policy(...)`, `buckets_views_list(...)`, `buckets_views_patch(...)`, `buckets_views_set_iam_policy(...)`, `buckets_views_test_iam_permissions(...)`, `get(...)`, `list(...)`, `operations_cancel(...)`, `operations_get(...)` and `operations_list(...)`
// to build up your call.
let rb = hub.locations();
Implementations§
Source§impl<'a, C> LocationMethods<'a, C>
impl<'a, C> LocationMethods<'a, C>
Sourcepub fn buckets_links_create(
&self,
request: Link,
parent: &str,
) -> LocationBucketLinkCreateCall<'a, C>
pub fn buckets_links_create( &self, request: Link, parent: &str, ) -> LocationBucketLinkCreateCall<'a, C>
Create a builder to help you perform the following task:
Asynchronously creates a linked dataset in BigQuery which makes it possible to use BigQuery to read the logs stored in the log bucket. A log bucket may currently only contain one link.
§Arguments
request
- No description provided.parent
- Required. The full resource name of the bucket to create a link for. “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]”
Sourcepub fn buckets_links_delete(
&self,
name: &str,
) -> LocationBucketLinkDeleteCall<'a, C>
pub fn buckets_links_delete( &self, name: &str, ) -> LocationBucketLinkDeleteCall<'a, C>
Create a builder to help you perform the following task:
Deletes a link. This will also delete the corresponding BigQuery linked dataset.
§Arguments
name
- Required. The full resource name of the link to delete. “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]”
Sourcepub fn buckets_links_get(&self, name: &str) -> LocationBucketLinkGetCall<'a, C>
pub fn buckets_links_get(&self, name: &str) -> LocationBucketLinkGetCall<'a, C>
Create a builder to help you perform the following task:
Gets a link.
§Arguments
name
- Required. The resource name of the link: “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/links/[LINK_ID]”
Sourcepub fn buckets_links_list(
&self,
parent: &str,
) -> LocationBucketLinkListCall<'a, C>
pub fn buckets_links_list( &self, parent: &str, ) -> LocationBucketLinkListCall<'a, C>
Create a builder to help you perform the following task:
Lists links.
§Arguments
parent
- Required. The parent resource whose links are to be listed: “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]”
Sourcepub fn buckets_views_create(
&self,
request: LogView,
parent: &str,
) -> LocationBucketViewCreateCall<'a, C>
pub fn buckets_views_create( &self, request: LogView, parent: &str, ) -> LocationBucketViewCreateCall<'a, C>
Create a builder to help you perform the following task:
Creates a view over log entries in a log bucket. A bucket may contain a maximum of 30 views.
§Arguments
request
- No description provided.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”
Sourcepub fn buckets_views_delete(
&self,
name: &str,
) -> LocationBucketViewDeleteCall<'a, C>
pub fn buckets_views_delete( &self, name: &str, ) -> LocationBucketViewDeleteCall<'a, C>
Create a builder to help you perform the following task:
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.
§Arguments
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”
Sourcepub fn buckets_views_get(&self, name: &str) -> LocationBucketViewGetCall<'a, C>
pub fn buckets_views_get(&self, name: &str) -> LocationBucketViewGetCall<'a, C>
Create a builder to help you perform the following task:
Gets a view on a log bucket.
§Arguments
name
- Required. The resource name of the policy: “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”
Sourcepub fn buckets_views_get_iam_policy(
&self,
request: GetIamPolicyRequest,
resource: &str,
) -> LocationBucketViewGetIamPolicyCall<'a, C>
pub fn buckets_views_get_iam_policy( &self, request: GetIamPolicyRequest, resource: &str, ) -> LocationBucketViewGetIamPolicyCall<'a, C>
Create a builder to help you perform the following task:
Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.
§Arguments
request
- No description provided.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.
Sourcepub fn buckets_views_list(
&self,
parent: &str,
) -> LocationBucketViewListCall<'a, C>
pub fn buckets_views_list( &self, parent: &str, ) -> LocationBucketViewListCall<'a, C>
Create a builder to help you perform the following task:
Lists views on a log bucket.
§Arguments
parent
- Required. The bucket whose views are to be listed: “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]”
Sourcepub fn buckets_views_patch(
&self,
request: LogView,
name: &str,
) -> LocationBucketViewPatchCall<'a, C>
pub fn buckets_views_patch( &self, request: LogView, name: &str, ) -> LocationBucketViewPatchCall<'a, C>
Create a builder to help you perform the following task:
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.
§Arguments
request
- No description provided.name
- Required. The full resource name of the view to update “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”
Sourcepub fn buckets_views_set_iam_policy(
&self,
request: SetIamPolicyRequest,
resource: &str,
) -> LocationBucketViewSetIamPolicyCall<'a, C>
pub fn buckets_views_set_iam_policy( &self, request: SetIamPolicyRequest, resource: &str, ) -> LocationBucketViewSetIamPolicyCall<'a, C>
Create a builder to help you perform the following task:
Sets the access control policy on the specified resource. Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.
§Arguments
request
- No description provided.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.
Sourcepub fn buckets_views_test_iam_permissions(
&self,
request: TestIamPermissionsRequest,
resource: &str,
) -> LocationBucketViewTestIamPermissionCall<'a, C>
pub fn buckets_views_test_iam_permissions( &self, request: TestIamPermissionsRequest, resource: &str, ) -> LocationBucketViewTestIamPermissionCall<'a, C>
Create a builder to help you perform the following task:
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.
§Arguments
request
- No description provided.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.
Sourcepub fn buckets_create(
&self,
request: LogBucket,
parent: &str,
) -> LocationBucketCreateCall<'a, C>
pub fn buckets_create( &self, request: LogBucket, parent: &str, ) -> LocationBucketCreateCall<'a, C>
Create a builder to help you perform the following task:
Creates a log bucket that can be used to store log entries. After a bucket has been created, the bucket’s location cannot be changed.
§Arguments
request
- No description provided.parent
- Required. The resource in which to create the log bucket: “projects/[PROJECT_ID]/locations/[LOCATION_ID]” For example:“projects/my-project/locations/global”
Sourcepub fn buckets_create_async(
&self,
request: LogBucket,
parent: &str,
) -> LocationBucketCreateAsyncCall<'a, C>
pub fn buckets_create_async( &self, request: LogBucket, parent: &str, ) -> LocationBucketCreateAsyncCall<'a, C>
Create a builder to help you perform the following task:
Creates a log bucket asynchronously that can be used to store log entries.After a bucket has been created, the bucket’s location cannot be changed.
§Arguments
request
- No description provided.parent
- Required. The resource in which to create the log bucket: “projects/[PROJECT_ID]/locations/[LOCATION_ID]” For example:“projects/my-project/locations/global”
Sourcepub fn buckets_delete(&self, name: &str) -> LocationBucketDeleteCall<'a, C>
pub fn buckets_delete(&self, name: &str) -> LocationBucketDeleteCall<'a, C>
Create a builder to help you perform the following task:
Deletes a log bucket.Changes the bucket’s lifecycle_state to the DELETE_REQUESTED state. After 7 days, the bucket will be purged and all log entries in the bucket will be permanently deleted.
§Arguments
name
- Required. The full resource name of the bucket to delete. “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” For example:“projects/my-project/locations/global/buckets/my-bucket”
Sourcepub fn buckets_get(&self, name: &str) -> LocationBucketGetCall<'a, C>
pub fn buckets_get(&self, name: &str) -> LocationBucketGetCall<'a, C>
Create a builder to help you perform the following task:
Gets a log bucket.
§Arguments
name
- Required. The resource name of the bucket: “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” For example:“projects/my-project/locations/global/buckets/my-bucket”
Sourcepub fn buckets_list(&self, parent: &str) -> LocationBucketListCall<'a, C>
pub fn buckets_list(&self, parent: &str) -> LocationBucketListCall<'a, C>
Create a builder to help you perform the following task:
Lists log buckets.
§Arguments
parent
- Required. The parent resource whose buckets are to be listed: “projects/[PROJECT_ID]/locations/[LOCATION_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]” Note: The locations portion of the resource must be specified, but supplying the character - in place of LOCATION_ID will return all buckets.
Sourcepub fn buckets_patch(
&self,
request: LogBucket,
name: &str,
) -> LocationBucketPatchCall<'a, C>
pub fn buckets_patch( &self, request: LogBucket, name: &str, ) -> LocationBucketPatchCall<'a, C>
Create a builder to help you perform the following task:
Updates a log bucket.If the bucket has a lifecycle_state of DELETE_REQUESTED, then FAILED_PRECONDITION will be returned.After a bucket has been created, the bucket’s location cannot be changed.
§Arguments
request
- No description provided.name
- Required. The full resource name of the bucket to update. “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” For example:“projects/my-project/locations/global/buckets/my-bucket”
Sourcepub fn buckets_undelete(
&self,
request: UndeleteBucketRequest,
name: &str,
) -> LocationBucketUndeleteCall<'a, C>
pub fn buckets_undelete( &self, request: UndeleteBucketRequest, name: &str, ) -> LocationBucketUndeleteCall<'a, C>
Create a builder to help you perform the following task:
Undeletes a log bucket. A bucket that has been deleted can be undeleted within the grace period of 7 days.
§Arguments
request
- No description provided.name
- Required. The full resource name of the bucket to undelete. “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” For example:“projects/my-project/locations/global/buckets/my-bucket”
Sourcepub fn buckets_update_async(
&self,
request: LogBucket,
name: &str,
) -> LocationBucketUpdateAsyncCall<'a, C>
pub fn buckets_update_async( &self, request: LogBucket, name: &str, ) -> LocationBucketUpdateAsyncCall<'a, C>
Create a builder to help you perform the following task:
Updates a log bucket asynchronously.If the bucket has a lifecycle_state of DELETE_REQUESTED, then FAILED_PRECONDITION will be returned.After a bucket has been created, the bucket’s location cannot be changed.
§Arguments
request
- No description provided.name
- Required. The full resource name of the bucket to update. “projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” “folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]” For example:“projects/my-project/locations/global/buckets/my-bucket”
Sourcepub fn operations_cancel(
&self,
request: CancelOperationRequest,
name: &str,
) -> LocationOperationCancelCall<'a, C>
pub fn operations_cancel( &self, request: CancelOperationRequest, name: &str, ) -> LocationOperationCancelCall<'a, C>
Create a builder to help you perform the following task:
Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn’t support this method, it returns google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to Code.CANCELLED.
§Arguments
request
- No description provided.name
- The name of the operation resource to be cancelled.
Sourcepub fn operations_get(&self, name: &str) -> LocationOperationGetCall<'a, C>
pub fn operations_get(&self, name: &str) -> LocationOperationGetCall<'a, C>
Create a builder to help you perform the following task:
Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.
§Arguments
name
- The name of the operation resource.
Sourcepub fn operations_list(&self, name: &str) -> LocationOperationListCall<'a, C>
pub fn operations_list(&self, name: &str) -> LocationOperationListCall<'a, C>
Create a builder to help you perform the following task:
Lists operations that match the specified filter in the request. If the server doesn’t support this method, it returns UNIMPLEMENTED.
§Arguments
name
- The name of the operation’s parent resource.
Sourcepub fn get(&self, name: &str) -> LocationGetCall<'a, C>
pub fn get(&self, name: &str) -> LocationGetCall<'a, C>
Create a builder to help you perform the following task:
Gets information about a location.
§Arguments
name
- Resource name for the location.
Sourcepub fn list(&self, name: &str) -> LocationListCall<'a, C>
pub fn list(&self, name: &str) -> LocationListCall<'a, C>
Create a builder to help you perform the following task:
Lists information about the supported locations for this service.
§Arguments
name
- The resource that owns the locations collection, if applicable.
Trait Implementations§
impl<'a, C> MethodsBuilder for LocationMethods<'a, C>
Auto Trait Implementations§
impl<'a, C> Freeze for LocationMethods<'a, C>
impl<'a, C> !RefUnwindSafe for LocationMethods<'a, C>
impl<'a, C> Send for LocationMethods<'a, C>where
C: Sync,
impl<'a, C> Sync for LocationMethods<'a, C>where
C: Sync,
impl<'a, C> Unpin for LocationMethods<'a, C>
impl<'a, C> !UnwindSafe for LocationMethods<'a, C>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more