#[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 create_access_grant;
mod create_access_profile;
mod create_alert;
mod create_domain;
mod create_domain_access_grant_for_organization;
mod create_domain_for_organization;
mod create_integration;
mod create_omni_dashboard;
mod create_one_time_deep_link_code;
mod create_space;
mod create_view;
pub mod customize;
mod delete_access_grant;
mod delete_access_profile;
mod delete_alert;
mod delete_domain;
mod delete_domain_access_grant_for_organization;
mod delete_domain_for_organization;
mod delete_integration;
mod delete_omni_dashboard;
mod delete_space;
mod delete_view;
mod get_access_grant;
mod get_access_profile;
mod get_alert;
mod get_context_graph;
mod get_domain;
mod get_domain_access_grant_for_organization;
mod get_domain_for_organization;
mod get_integration;
mod get_intelligence_configuration;
mod get_omni_dashboard;
mod get_space;
mod get_space_credentials_for_organization;
mod get_telemetry_query_results;
mod get_view;
mod list_access_grants;
mod list_access_profiles;
mod list_alerts;
mod list_domain_access_grants_for_organization;
mod list_domains;
mod list_integrations;
mod list_omni_dashboards;
mod list_spaces;
mod list_spaces_for_organization;
mod list_telemetry_fields;
mod list_telemetry_query_sessions;
mod list_views;
mod put_intelligence_configuration;
mod search_principals;
mod start_telemetry_query;
mod start_telemetry_query_session;
mod stop_telemetry_query;
mod stop_telemetry_query_session;
mod update_access_profile;
mod update_alert;
mod update_domain;
mod update_domain_for_organization;
mod update_integration;
mod update_omni_dashboard;
mod update_space;
mod update_view;