pub struct PageMethods<'a, C>where
C: 'a,{ /* private fields */ }Expand description
A builder providing access to all methods supported on page resources.
It is not used directly, but through the Blogger hub.
§Example
Instantiate a resource builder
extern crate hyper;
extern crate hyper_rustls;
extern crate google_blogger3 as blogger3;
use blogger3::{Blogger, FieldMask, hyper_rustls, hyper_util, yup_oauth2};
let secret: yup_oauth2::ApplicationSecret = Default::default();
let connector = hyper_rustls::HttpsConnectorBuilder::new()
.with_native_roots()
.unwrap()
.https_only()
.enable_http2()
.build();
let executor = hyper_util::rt::TokioExecutor::new();
let auth = yup_oauth2::InstalledFlowAuthenticator::with_client(
secret,
yup_oauth2::InstalledFlowReturnMethod::HTTPRedirect,
yup_oauth2::client::CustomHyperClientBuilder::from(
hyper_util::client::legacy::Client::builder(executor).build(connector),
),
).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_http2()
.build()
);
let mut hub = Blogger::new(client, auth);
// Usually you wouldn't bind this to a variable, but keep calling *CallBuilders*
// like `delete(...)`, `get(...)`, `insert(...)`, `list(...)`, `patch(...)`, `publish(...)`, `revert(...)` and `update(...)`
// to build up your call.
let rb = hub.pages();Implementations§
Source§impl<'a, C> PageMethods<'a, C>
impl<'a, C> PageMethods<'a, C>
Sourcepub fn delete(&self, blog_id: &str, page_id: &str) -> PageDeleteCall<'a, C>
pub fn delete(&self, blog_id: &str, page_id: &str) -> PageDeleteCall<'a, C>
Create a builder to help you perform the following task:
Deletes a page by blog id and page id.
§Arguments
blogId- No description provided.pageId- No description provided.
Sourcepub fn get(&self, blog_id: &str, page_id: &str) -> PageGetCall<'a, C>
pub fn get(&self, blog_id: &str, page_id: &str) -> PageGetCall<'a, C>
Create a builder to help you perform the following task:
Gets a page by blog id and page id.
§Arguments
blogId- No description provided.pageId- No description provided.
Sourcepub fn insert(&self, request: Page, blog_id: &str) -> PageInsertCall<'a, C>
pub fn insert(&self, request: Page, blog_id: &str) -> PageInsertCall<'a, C>
Create a builder to help you perform the following task:
Inserts a page.
§Arguments
request- No description provided.blogId- No description provided.
Sourcepub fn list(&self, blog_id: &str) -> PageListCall<'a, C>
pub fn list(&self, blog_id: &str) -> PageListCall<'a, C>
Create a builder to help you perform the following task:
Lists pages.
§Arguments
blogId- No description provided.
Sourcepub fn patch(
&self,
request: Page,
blog_id: &str,
page_id: &str,
) -> PagePatchCall<'a, C>
pub fn patch( &self, request: Page, blog_id: &str, page_id: &str, ) -> PagePatchCall<'a, C>
Create a builder to help you perform the following task:
Patches a page.
§Arguments
request- No description provided.blogId- No description provided.pageId- No description provided.
Sourcepub fn publish(&self, blog_id: &str, page_id: &str) -> PagePublishCall<'a, C>
pub fn publish(&self, blog_id: &str, page_id: &str) -> PagePublishCall<'a, C>
Create a builder to help you perform the following task:
Publishes a page.
§Arguments
blogId- No description provided.pageId- No description provided.
Sourcepub fn revert(&self, blog_id: &str, page_id: &str) -> PageRevertCall<'a, C>
pub fn revert(&self, blog_id: &str, page_id: &str) -> PageRevertCall<'a, C>
Create a builder to help you perform the following task:
Reverts a published or scheduled page to draft state.
§Arguments
blogId- No description provided.pageId- No description provided.
Sourcepub fn update(
&self,
request: Page,
blog_id: &str,
page_id: &str,
) -> PageUpdateCall<'a, C>
pub fn update( &self, request: Page, blog_id: &str, page_id: &str, ) -> PageUpdateCall<'a, C>
Create a builder to help you perform the following task:
Updates a page by blog id and page id.
§Arguments
request- No description provided.blogId- No description provided.pageId- No description provided.