#[derive(Debug)]
pub(crate) struct Handle {
pub(crate) conf: crate::Config,
#[allow(dead_code)] pub(crate) runtime_plugins: ::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
}
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
pub struct Client {
handle: ::std::sync::Arc<Handle>,
}
impl Client {
#[track_caller]
pub fn from_conf(conf: crate::Config) -> Self {
let handle = Handle {
conf: conf.clone(),
runtime_plugins: crate::config::base_client_runtime_plugins(conf),
};
if let Err(err) = Self::validate_config(&handle) {
panic!("Invalid client configuration: {err}");
}
Self {
handle: ::std::sync::Arc::new(handle),
}
}
pub fn config(&self) -> &crate::Config {
&self.handle.conf
}
fn validate_config(handle: &Handle) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
let mut cfg = ::aws_smithy_types::config_bag::ConfigBag::base();
handle
.runtime_plugins
.apply_client_configuration(&mut cfg)?
.validate_base_client_config(&cfg)?;
Ok(())
}
}
impl Client {
#[track_caller]
pub fn new(sdk_config: &::aws_types::sdk_config::SdkConfig) -> Self {
Self::from_conf(sdk_config.into())
}
}
mod activate_gateway;
mod add_cache;
mod add_tags_to_resource;
mod add_upload_buffer;
mod add_working_storage;
mod assign_tape_pool;
mod associate_file_system;
mod attach_volume;
mod cancel_archival;
mod cancel_cache_report;
mod cancel_retrieval;
mod create_cachedi_scsi_volume;
mod create_nfs_file_share;
mod create_smb_file_share;
mod create_snapshot;
mod create_snapshot_from_volume_recovery_point;
mod create_storedi_scsi_volume;
mod create_tape_pool;
mod create_tape_with_barcode;
mod create_tapes;
pub mod customize;
mod delete_automatic_tape_creation_policy;
mod delete_bandwidth_rate_limit;
mod delete_cache_report;
mod delete_chap_credentials;
mod delete_file_share;
mod delete_gateway;
mod delete_snapshot_schedule;
mod delete_tape;
mod delete_tape_archive;
mod delete_tape_pool;
mod delete_volume;
mod describe_availability_monitor_test;
mod describe_bandwidth_rate_limit;
mod describe_bandwidth_rate_limit_schedule;
mod describe_cache;
mod describe_cache_report;
mod describe_cachedi_scsi_volumes;
mod describe_chap_credentials;
mod describe_file_system_associations;
mod describe_gateway_information;
mod describe_maintenance_start_time;
mod describe_nfs_file_shares;
mod describe_smb_file_shares;
mod describe_smb_settings;
mod describe_snapshot_schedule;
mod describe_storedi_scsi_volumes;
mod describe_tape_archives;
mod describe_tape_recovery_points;
mod describe_tapes;
mod describe_upload_buffer;
mod describe_vtl_devices;
mod describe_working_storage;
mod detach_volume;
mod disable_gateway;
mod disassociate_file_system;
mod evict_files_failing_upload;
mod join_domain;
mod list_automatic_tape_creation_policies;
mod list_cache_reports;
mod list_file_shares;
mod list_file_system_associations;
mod list_gateways;
mod list_local_disks;
mod list_tags_for_resource;
mod list_tape_pools;
mod list_tapes;
mod list_volume_initiators;
mod list_volume_recovery_points;
mod list_volumes;
mod notify_when_uploaded;
mod refresh_cache;
mod remove_tags_from_resource;
mod reset_cache;
mod retrieve_tape_archive;
mod retrieve_tape_recovery_point;
mod set_local_console_password;
mod set_smb_guest_password;
mod shutdown_gateway;
mod start_availability_monitor_test;
mod start_cache_report;
mod start_gateway;
mod update_automatic_tape_creation_policy;
mod update_bandwidth_rate_limit;
mod update_bandwidth_rate_limit_schedule;
mod update_chap_credentials;
mod update_file_system_association;
mod update_gateway_information;
mod update_gateway_software_now;
mod update_maintenance_start_time;
mod update_nfs_file_share;
mod update_smb_file_share;
mod update_smb_file_share_visibility;
mod update_smb_local_groups;
mod update_smb_security_strategy;
mod update_snapshot_schedule;
mod update_vtl_device_type;