Struct vault_api::client::Client
[−]
[src]
pub struct Client { /* fields omitted */ }
A client that implements the API by making HTTP calls out to a server.
Methods
impl Client
[src]
pub fn try_new_http<T>(base_path: T) -> Result<Client, ClientInitError> where
T: IntoUrl,
[src]
T: IntoUrl,
pub fn try_new_https<T, CA>(
base_path: T,
ca_certificate: CA
) -> Result<Client, ClientInitError> where
T: IntoUrl,
CA: AsRef<Path>,
[src]
base_path: T,
ca_certificate: CA
) -> Result<Client, ClientInitError> where
T: IntoUrl,
CA: AsRef<Path>,
pub fn try_new_https_mutual<T, CA, K, C>(
base_path: T,
ca_certificate: CA,
client_key: K,
client_certificate: C
) -> Result<Client, ClientInitError> where
T: IntoUrl,
CA: AsRef<Path>,
K: AsRef<Path>,
C: AsRef<Path>,
[src]
base_path: T,
ca_certificate: CA,
client_key: K,
client_certificate: C
) -> Result<Client, ClientInitError> where
T: IntoUrl,
CA: AsRef<Path>,
K: AsRef<Path>,
C: AsRef<Path>,
pub fn try_new_with_hyper_client<T>(
base_path: T,
hyper_client: Arc<Fn() -> Client + Sync + Send>
) -> Result<Client, ClientInitError> where
T: IntoUrl,
[src]
base_path: T,
hyper_client: Arc<Fn() -> Client + Sync + Send>
) -> Result<Client, ClientInitError> where
T: IntoUrl,
Constructor for creating a Client
by passing in a pre-made hyper
client.
One should avoid relying on this function if possible, since it adds a dependency on the underlying transport implementation, which it would be better to abstract away. Therefore, using this function may lead to a loss of code generality, which may make it harder to move the application to a serverless environment, for example.
The reason for this function's existence is to support legacy test code, which did mocking at the hyper layer. This is not a recommended way to write new tests. If other reasons are found for using this function, they should be mentioned here.
Trait Implementations
impl Clone for Client
[src]
fn clone(&self) -> Client
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for Client
[src]
fn fmt(&self, f: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Api for Client
[src]
ⓘImportant traits for Box<W>fn sys_leases_revoke_put(
&self,
param_x_vault_token: String,
param_body: RevokeLeaseParameters,
context: &Context
) -> Box<Future<Item = SysLeasesRevokePutResponse, Error = ApiError> + Send>
[src]
&self,
param_x_vault_token: String,
param_body: RevokeLeaseParameters,
context: &Context
) -> Box<Future<Item = SysLeasesRevokePutResponse, Error = ApiError> + Send>
Revoke lease
ⓘImportant traits for Box<W>fn generate_cert(
&self,
param_x_vault_token: String,
param_mount: String,
param_name: String,
param_body: GenerateCertificateParameters,
context: &Context
) -> Box<Future<Item = GenerateCertResponse, Error = ApiError> + Send>
[src]
&self,
param_x_vault_token: String,
param_mount: String,
param_name: String,
param_body: GenerateCertificateParameters,
context: &Context
) -> Box<Future<Item = GenerateCertResponse, Error = ApiError> + Send>
Generate certificate
ⓘImportant traits for Box<W>fn read_cert(
&self,
param_mount: String,
param_serial: String,
context: &Context
) -> Box<Future<Item = ReadCertResponse, Error = ApiError> + Send>
[src]
&self,
param_mount: String,
param_serial: String,
context: &Context
) -> Box<Future<Item = ReadCertResponse, Error = ApiError> + Send>
Read certificate
ⓘImportant traits for Box<W>fn create_orphan_token(
&self,
param_x_vault_token: String,
param_body: CreateTokenParameters,
context: &Context
) -> Box<Future<Item = CreateOrphanTokenResponse, Error = ApiError> + Send>
[src]
&self,
param_x_vault_token: String,
param_body: CreateTokenParameters,
context: &Context
) -> Box<Future<Item = CreateOrphanTokenResponse, Error = ApiError> + Send>
Create an orphan token
ⓘImportant traits for Box<W>fn create_token(
&self,
param_x_vault_token: String,
param_body: CreateTokenParameters,
context: &Context
) -> Box<Future<Item = CreateTokenResponse, Error = ApiError> + Send>
[src]
&self,
param_x_vault_token: String,
param_body: CreateTokenParameters,
context: &Context
) -> Box<Future<Item = CreateTokenResponse, Error = ApiError> + Send>
Create token
ⓘImportant traits for Box<W>fn log_in_with_tls_certificate(
&self,
param_body: Option<AuthCertLoginParameters>,
context: &Context
) -> Box<Future<Item = LogInWithTLSCertificateResponse, Error = ApiError> + Send>
[src]
&self,
param_body: Option<AuthCertLoginParameters>,
context: &Context
) -> Box<Future<Item = LogInWithTLSCertificateResponse, Error = ApiError> + Send>
Log in
ⓘImportant traits for Box<W>fn renew_own_token(
&self,
param_x_vault_token: String,
param_body: RenewSelfParameters,
context: &Context
) -> Box<Future<Item = RenewOwnTokenResponse, Error = ApiError> + Send>
[src]
&self,
param_x_vault_token: String,
param_body: RenewSelfParameters,
context: &Context
) -> Box<Future<Item = RenewOwnTokenResponse, Error = ApiError> + Send>
Renew own token