Struct ResourceMethods

Source
pub struct ResourceMethods<'a, C, A>
where C: 'a, A: 'a,
{ /* private fields */ }
Expand description

A builder providing access to all methods supported on resource resources. It is not used directly, but through the Directory hub.

§Example

Instantiate a resource builder

extern crate hyper;
extern crate hyper_rustls;
extern crate yup_oauth2 as oauth2;
extern crate google_admin1_directory as admin1_directory;
 
use std::default::Default;
use oauth2::{Authenticator, DefaultAuthenticatorDelegate, ApplicationSecret, MemoryStorage};
use admin1_directory::Directory;
 
let secret: ApplicationSecret = Default::default();
let auth = Authenticator::new(&secret, DefaultAuthenticatorDelegate,
                              hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())),
                              <MemoryStorage as Default>::default(), None);
let mut hub = Directory::new(hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())), auth);
// Usually you wouldn't bind this to a variable, but keep calling *CallBuilders*
// like `buildings_delete(...)`, `buildings_get(...)`, `buildings_insert(...)`, `buildings_list(...)`, `buildings_patch(...)`, `buildings_update(...)`, `calendars_delete(...)`, `calendars_get(...)`, `calendars_insert(...)`, `calendars_list(...)`, `calendars_patch(...)`, `calendars_update(...)`, `features_delete(...)`, `features_get(...)`, `features_insert(...)`, `features_list(...)`, `features_patch(...)`, `features_rename(...)` and `features_update(...)`
// to build up your call.
let rb = hub.resources();

Implementations§

Source§

impl<'a, C, A> ResourceMethods<'a, C, A>

Source

pub fn calendars_list( &self, customer: &str, ) -> ResourceCalendarListCall<'a, C, A>

Create a builder to help you perform the following task:

Retrieves a list of calendar resources for an account.

§Arguments
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
Source

pub fn features_rename( &self, request: FeatureRename, customer: &str, old_name: &str, ) -> ResourceFeatureRenameCall<'a, C, A>

Create a builder to help you perform the following task:

Renames a feature.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • oldName - The unique ID of the feature to rename.
Source

pub fn features_insert( &self, request: Feature, customer: &str, ) -> ResourceFeatureInsertCall<'a, C, A>

Create a builder to help you perform the following task:

Inserts a feature.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
Source

pub fn buildings_update( &self, request: Building, customer: &str, building_id: &str, ) -> ResourceBuildingUpdateCall<'a, C, A>

Create a builder to help you perform the following task:

Updates a building.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • buildingId - The ID of the building to update.
Source

pub fn buildings_delete( &self, customer: &str, building_id: &str, ) -> ResourceBuildingDeleteCall<'a, C, A>

Create a builder to help you perform the following task:

Deletes a building.

§Arguments
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • buildingId - The ID of the building to delete.
Source

pub fn features_list(&self, customer: &str) -> ResourceFeatureListCall<'a, C, A>

Create a builder to help you perform the following task:

Retrieves a list of features for an account.

§Arguments
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
Source

pub fn calendars_get( &self, customer: &str, calendar_resource_id: &str, ) -> ResourceCalendarGetCall<'a, C, A>

Create a builder to help you perform the following task:

Retrieves a calendar resource.

§Arguments
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • calendarResourceId - The unique ID of the calendar resource to retrieve.
Source

pub fn buildings_patch( &self, request: Building, customer: &str, building_id: &str, ) -> ResourceBuildingPatchCall<'a, C, A>

Create a builder to help you perform the following task:

Updates a building. This method supports patch semantics.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • buildingId - The ID of the building to update.
Source

pub fn buildings_list( &self, customer: &str, ) -> ResourceBuildingListCall<'a, C, A>

Create a builder to help you perform the following task:

Retrieves a list of buildings for an account.

§Arguments
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
Source

pub fn features_get( &self, customer: &str, feature_key: &str, ) -> ResourceFeatureGetCall<'a, C, A>

Create a builder to help you perform the following task:

Retrieves a feature.

§Arguments
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • featureKey - The unique ID of the feature to retrieve.
Source

pub fn calendars_insert( &self, request: CalendarResource, customer: &str, ) -> ResourceCalendarInsertCall<'a, C, A>

Create a builder to help you perform the following task:

Inserts a calendar resource.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
Source

pub fn features_patch( &self, request: Feature, customer: &str, feature_key: &str, ) -> ResourceFeaturePatchCall<'a, C, A>

Create a builder to help you perform the following task:

Updates a feature. This method supports patch semantics.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • featureKey - The unique ID of the feature to update.
Source

pub fn buildings_get( &self, customer: &str, building_id: &str, ) -> ResourceBuildingGetCall<'a, C, A>

Create a builder to help you perform the following task:

Retrieves a building.

§Arguments
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • buildingId - The unique ID of the building to retrieve.
Source

pub fn features_delete( &self, customer: &str, feature_key: &str, ) -> ResourceFeatureDeleteCall<'a, C, A>

Create a builder to help you perform the following task:

Deletes a feature.

§Arguments
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • featureKey - The unique ID of the feature to delete.
Source

pub fn features_update( &self, request: Feature, customer: &str, feature_key: &str, ) -> ResourceFeatureUpdateCall<'a, C, A>

Create a builder to help you perform the following task:

Updates a feature.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • featureKey - The unique ID of the feature to update.
Source

pub fn buildings_insert( &self, request: Building, customer: &str, ) -> ResourceBuildingInsertCall<'a, C, A>

Create a builder to help you perform the following task:

Inserts a building.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
Source

pub fn calendars_patch( &self, request: CalendarResource, customer: &str, calendar_resource_id: &str, ) -> ResourceCalendarPatchCall<'a, C, A>

Create a builder to help you perform the following task:

Updates a calendar resource.

This method supports patch semantics, meaning you only need to include the fields you wish to update. Fields that are not present in the request will be preserved. This method supports patch semantics.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • calendarResourceId - The unique ID of the calendar resource to update.
Source

pub fn calendars_update( &self, request: CalendarResource, customer: &str, calendar_resource_id: &str, ) -> ResourceCalendarUpdateCall<'a, C, A>

Create a builder to help you perform the following task:

Updates a calendar resource.

This method supports patch semantics, meaning you only need to include the fields you wish to update. Fields that are not present in the request will be preserved.

§Arguments
  • request - No description provided.
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • calendarResourceId - The unique ID of the calendar resource to update.
Source

pub fn calendars_delete( &self, customer: &str, calendar_resource_id: &str, ) -> ResourceCalendarDeleteCall<'a, C, A>

Create a builder to help you perform the following task:

Deletes a calendar resource.

§Arguments
  • customer - The unique ID for the customer’s G Suite account. As an account administrator, you can also use the my_customer alias to represent your account’s customer ID.
  • calendarResourceId - The unique ID of the calendar resource to delete.

Trait Implementations§

Source§

impl<'a, C, A> MethodsBuilder for ResourceMethods<'a, C, A>

Auto Trait Implementations§

§

impl<'a, C, A> Freeze for ResourceMethods<'a, C, A>

§

impl<'a, C, A> !RefUnwindSafe for ResourceMethods<'a, C, A>

§

impl<'a, C, A> !Send for ResourceMethods<'a, C, A>

§

impl<'a, C, A> !Sync for ResourceMethods<'a, C, A>

§

impl<'a, C, A> Unpin for ResourceMethods<'a, C, A>

§

impl<'a, C, A> !UnwindSafe for ResourceMethods<'a, C, A>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts 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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts 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
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> Typeable for T
where T: Any,

Source§

fn get_type(&self) -> TypeId

Get the TypeId of this object.