Struct google_plus1::api::PersonMethods
source · pub struct PersonMethods<'a, S>where
S: 'a,{ /* private fields */ }
Expand description
A builder providing access to all methods supported on person resources.
It is not used directly, but through the Plus
hub.
§Example
Instantiate a resource builder
extern crate hyper;
extern crate hyper_rustls;
extern crate google_plus1 as plus1;
use std::default::Default;
use plus1::{Plus, oauth2, hyper, hyper_rustls, chrono, FieldMask};
let secret: oauth2::ApplicationSecret = Default::default();
let auth = oauth2::InstalledFlowAuthenticator::builder(
secret,
oauth2::InstalledFlowReturnMethod::HTTPRedirect,
).build().await.unwrap();
let mut hub = Plus::new(hyper::Client::builder().build(hyper_rustls::HttpsConnectorBuilder::new().with_native_roots().https_or_http().enable_http1().build()), auth);
// Usually you wouldn't bind this to a variable, but keep calling *CallBuilders*
// like `get(...)`, `list(...)`, `list_by_activity(...)` and `search(...)`
// to build up your call.
let rb = hub.people();
Implementations§
source§impl<'a, S> PersonMethods<'a, S>
impl<'a, S> PersonMethods<'a, S>
sourcepub fn get(&self, user_id: &str) -> PersonGetCall<'a, S>
pub fn get(&self, user_id: &str) -> PersonGetCall<'a, S>
Create a builder to help you perform the following task:
Get a person’s profile. If your app uses scope https://www.googleapis.com/auth/plus.login, this method is guaranteed to return ageRange and language.
§Arguments
userId
- The ID of the person to get the profile for. The special value “me” can be used to indicate the authenticated user.
sourcepub fn list(&self, user_id: &str, collection: &str) -> PersonListCall<'a, S>
pub fn list(&self, user_id: &str, collection: &str) -> PersonListCall<'a, S>
Create a builder to help you perform the following task:
List all of the people in the specified collection.
§Arguments
userId
- Get the collection of people for the person identified. Use “me” to indicate the authenticated user.collection
- The collection of people to list.
sourcepub fn list_by_activity(
&self,
activity_id: &str,
collection: &str
) -> PersonListByActivityCall<'a, S>
pub fn list_by_activity( &self, activity_id: &str, collection: &str ) -> PersonListByActivityCall<'a, S>
Create a builder to help you perform the following task:
Shut down. See https://developers.google.com/+/api-shutdown for more details.
§Arguments
activityId
- The ID of the activity to get the list of people for.collection
- The collection of people to list.
sourcepub fn search(&self, query: &str) -> PersonSearchCall<'a, S>
pub fn search(&self, query: &str) -> PersonSearchCall<'a, S>
Create a builder to help you perform the following task:
Shut down. See https://developers.google.com/+/api-shutdown for more details.
§Arguments
query
- Specify a query string for full text search of public text in all profiles.
Trait Implementations§
impl<'a, S> MethodsBuilder for PersonMethods<'a, S>
Auto Trait Implementations§
impl<'a, S> !RefUnwindSafe for PersonMethods<'a, S>
impl<'a, S> Send for PersonMethods<'a, S>where
S: Sync,
impl<'a, S> Sync for PersonMethods<'a, S>where
S: Sync,
impl<'a, S> Unpin for PersonMethods<'a, S>
impl<'a, S> !UnwindSafe for PersonMethods<'a, S>
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
Mutably borrows from an owned value. Read more