chore(regen-apis): Update examples

This commit is contained in:
Sebastian Thiel
2017-05-26 10:19:44 +02:00
parent 4660d23676
commit fc4ff6fe8b
435 changed files with 14253 additions and 16572 deletions

View File

@@ -14,6 +14,9 @@ license = "MIT"
keywords = ["firebasedynamiclinks", "google", "protocol", "web", "api"]
[dev-dependencies]
hyper-rustls = "^0.6"
[dependencies]
hyper = "^ 0.10"
mime = "^ 0.2.0"

View File

@@ -70,6 +70,7 @@ google-firebasedynamiclinks1 = "*"
```Rust
extern crate hyper;
extern crate hyper_rustls;
extern crate yup_oauth2 as oauth2;
extern crate google_firebasedynamiclinks1 as firebasedynamiclinks1;
use firebasedynamiclinks1::CreateShortDynamicLinkRequest;
@@ -87,9 +88,9 @@ let secret: ApplicationSecret = Default::default();
// what's going on. You probably want to bring in your own `TokenStorage` to persist tokens and
// retrieve them from storage.
let auth = Authenticator::new(&secret, DefaultAuthenticatorDelegate,
hyper::Client::new(),
hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())),
<MemoryStorage as Default>::default(), None);
let mut hub = FirebaseDynamicLinks::new(hyper::Client::new(), auth);
let mut hub = FirebaseDynamicLinks::new(hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())), auth);
// As the method needs a request, you would usually fill it with the desired information
// into the respective structure. Some of the parts shown here might not be applicable !
// Values shown here are possibly random and not representative !

View File

@@ -70,6 +70,7 @@
//!
//! ```test_harness,no_run
//! extern crate hyper;
//! extern crate hyper_rustls;
//! extern crate yup_oauth2 as oauth2;
//! extern crate google_firebasedynamiclinks1 as firebasedynamiclinks1;
//! use firebasedynamiclinks1::CreateShortDynamicLinkRequest;
@@ -88,9 +89,9 @@
//! // what's going on. You probably want to bring in your own `TokenStorage` to persist tokens and
//! // retrieve them from storage.
//! let auth = Authenticator::new(&secret, DefaultAuthenticatorDelegate,
//! hyper::Client::new(),
//! hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())),
//! <MemoryStorage as Default>::default(), None);
//! let mut hub = FirebaseDynamicLinks::new(hyper::Client::new(), auth);
//! let mut hub = FirebaseDynamicLinks::new(hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())), auth);
//! // As the method needs a request, you would usually fill it with the desired information
//! // into the respective structure. Some of the parts shown here might not be applicable !
//! // Values shown here are possibly random and not representative !
@@ -254,6 +255,7 @@ impl Default for Scope {
///
/// ```test_harness,no_run
/// extern crate hyper;
/// extern crate hyper_rustls;
/// extern crate yup_oauth2 as oauth2;
/// extern crate google_firebasedynamiclinks1 as firebasedynamiclinks1;
/// use firebasedynamiclinks1::CreateShortDynamicLinkRequest;
@@ -272,9 +274,9 @@ impl Default for Scope {
/// // what's going on. You probably want to bring in your own `TokenStorage` to persist tokens and
/// // retrieve them from storage.
/// let auth = Authenticator::new(&secret, DefaultAuthenticatorDelegate,
/// hyper::Client::new(),
/// hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())),
/// <MemoryStorage as Default>::default(), None);
/// let mut hub = FirebaseDynamicLinks::new(hyper::Client::new(), auth);
/// let mut hub = FirebaseDynamicLinks::new(hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())), auth);
/// // As the method needs a request, you would usually fill it with the desired information
/// // into the respective structure. Some of the parts shown here might not be applicable !
/// // Values shown here are possibly random and not representative !
@@ -663,6 +665,7 @@ impl ResponseResult for CreateShortDynamicLinkResponse {}
///
/// ```test_harness,no_run
/// extern crate hyper;
/// extern crate hyper_rustls;
/// extern crate yup_oauth2 as oauth2;
/// extern crate google_firebasedynamiclinks1 as firebasedynamiclinks1;
///
@@ -673,9 +676,9 @@ impl ResponseResult for CreateShortDynamicLinkResponse {}
///
/// let secret: ApplicationSecret = Default::default();
/// let auth = Authenticator::new(&secret, DefaultAuthenticatorDelegate,
/// hyper::Client::new(),
/// hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())),
/// <MemoryStorage as Default>::default(), None);
/// let mut hub = FirebaseDynamicLinks::new(hyper::Client::new(), auth);
/// let mut hub = FirebaseDynamicLinks::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 `create(...)`
/// // to build up your call.
@@ -745,6 +748,7 @@ impl<'a, C, A> ShortLinkMethods<'a, C, A> {
///
/// ```test_harness,no_run
/// # extern crate hyper;
/// # extern crate hyper_rustls;
/// # extern crate yup_oauth2 as oauth2;
/// # extern crate google_firebasedynamiclinks1 as firebasedynamiclinks1;
/// use firebasedynamiclinks1::CreateShortDynamicLinkRequest;
@@ -755,9 +759,9 @@ impl<'a, C, A> ShortLinkMethods<'a, C, A> {
///
/// # let secret: ApplicationSecret = Default::default();
/// # let auth = Authenticator::new(&secret, DefaultAuthenticatorDelegate,
/// # hyper::Client::new(),
/// # hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())),
/// # <MemoryStorage as Default>::default(), None);
/// # let mut hub = FirebaseDynamicLinks::new(hyper::Client::new(), auth);
/// # let mut hub = FirebaseDynamicLinks::new(hyper::Client::with_connector(hyper::net::HttpsConnector::new(hyper_rustls::TlsClient::new())), auth);
/// // As the method needs a request, you would usually fill it with the desired information
/// // into the respective structure. Some of the parts shown here might not be applicable !
/// // Values shown here are possibly random and not representative !