#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct ProxySession {
pub voice_connector_id: ::std::option::Option<::std::string::String>,
pub proxy_session_id: ::std::option::Option<::std::string::String>,
pub name: ::std::option::Option<::std::string::String>,
pub status: ::std::option::Option<crate::types::ProxySessionStatus>,
pub expiry_minutes: ::std::option::Option<i32>,
pub capabilities: ::std::option::Option<::std::vec::Vec<crate::types::Capability>>,
pub created_timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
pub updated_timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
pub ended_timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
pub participants: ::std::option::Option<::std::vec::Vec<crate::types::Participant>>,
pub number_selection_behavior: ::std::option::Option<crate::types::NumberSelectionBehavior>,
pub geo_match_level: ::std::option::Option<crate::types::GeoMatchLevel>,
pub geo_match_params: ::std::option::Option<crate::types::GeoMatchParams>,
}
impl ProxySession {
pub fn voice_connector_id(&self) -> ::std::option::Option<&str> {
self.voice_connector_id.as_deref()
}
pub fn proxy_session_id(&self) -> ::std::option::Option<&str> {
self.proxy_session_id.as_deref()
}
pub fn name(&self) -> ::std::option::Option<&str> {
self.name.as_deref()
}
pub fn status(&self) -> ::std::option::Option<&crate::types::ProxySessionStatus> {
self.status.as_ref()
}
pub fn expiry_minutes(&self) -> ::std::option::Option<i32> {
self.expiry_minutes
}
pub fn capabilities(&self) -> &[crate::types::Capability] {
self.capabilities.as_deref().unwrap_or_default()
}
pub fn created_timestamp(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.created_timestamp.as_ref()
}
pub fn updated_timestamp(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.updated_timestamp.as_ref()
}
pub fn ended_timestamp(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.ended_timestamp.as_ref()
}
pub fn participants(&self) -> &[crate::types::Participant] {
self.participants.as_deref().unwrap_or_default()
}
pub fn number_selection_behavior(&self) -> ::std::option::Option<&crate::types::NumberSelectionBehavior> {
self.number_selection_behavior.as_ref()
}
pub fn geo_match_level(&self) -> ::std::option::Option<&crate::types::GeoMatchLevel> {
self.geo_match_level.as_ref()
}
pub fn geo_match_params(&self) -> ::std::option::Option<&crate::types::GeoMatchParams> {
self.geo_match_params.as_ref()
}
}
impl ProxySession {
pub fn builder() -> crate::types::builders::ProxySessionBuilder {
crate::types::builders::ProxySessionBuilder::default()
}
}
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct ProxySessionBuilder {
pub(crate) voice_connector_id: ::std::option::Option<::std::string::String>,
pub(crate) proxy_session_id: ::std::option::Option<::std::string::String>,
pub(crate) name: ::std::option::Option<::std::string::String>,
pub(crate) status: ::std::option::Option<crate::types::ProxySessionStatus>,
pub(crate) expiry_minutes: ::std::option::Option<i32>,
pub(crate) capabilities: ::std::option::Option<::std::vec::Vec<crate::types::Capability>>,
pub(crate) created_timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) updated_timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) ended_timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) participants: ::std::option::Option<::std::vec::Vec<crate::types::Participant>>,
pub(crate) number_selection_behavior: ::std::option::Option<crate::types::NumberSelectionBehavior>,
pub(crate) geo_match_level: ::std::option::Option<crate::types::GeoMatchLevel>,
pub(crate) geo_match_params: ::std::option::Option<crate::types::GeoMatchParams>,
}
impl ProxySessionBuilder {
pub fn voice_connector_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.voice_connector_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_voice_connector_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.voice_connector_id = input;
self
}
pub fn get_voice_connector_id(&self) -> &::std::option::Option<::std::string::String> {
&self.voice_connector_id
}
pub fn proxy_session_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.proxy_session_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_proxy_session_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.proxy_session_id = input;
self
}
pub fn get_proxy_session_id(&self) -> &::std::option::Option<::std::string::String> {
&self.proxy_session_id
}
pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.name = ::std::option::Option::Some(input.into());
self
}
pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.name = input;
self
}
pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
&self.name
}
pub fn status(mut self, input: crate::types::ProxySessionStatus) -> Self {
self.status = ::std::option::Option::Some(input);
self
}
pub fn set_status(mut self, input: ::std::option::Option<crate::types::ProxySessionStatus>) -> Self {
self.status = input;
self
}
pub fn get_status(&self) -> &::std::option::Option<crate::types::ProxySessionStatus> {
&self.status
}
pub fn expiry_minutes(mut self, input: i32) -> Self {
self.expiry_minutes = ::std::option::Option::Some(input);
self
}
pub fn set_expiry_minutes(mut self, input: ::std::option::Option<i32>) -> Self {
self.expiry_minutes = input;
self
}
pub fn get_expiry_minutes(&self) -> &::std::option::Option<i32> {
&self.expiry_minutes
}
pub fn capabilities(mut self, input: crate::types::Capability) -> Self {
let mut v = self.capabilities.unwrap_or_default();
v.push(input);
self.capabilities = ::std::option::Option::Some(v);
self
}
pub fn set_capabilities(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Capability>>) -> Self {
self.capabilities = input;
self
}
pub fn get_capabilities(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Capability>> {
&self.capabilities
}
pub fn created_timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.created_timestamp = ::std::option::Option::Some(input);
self
}
pub fn set_created_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.created_timestamp = input;
self
}
pub fn get_created_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.created_timestamp
}
pub fn updated_timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.updated_timestamp = ::std::option::Option::Some(input);
self
}
pub fn set_updated_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.updated_timestamp = input;
self
}
pub fn get_updated_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.updated_timestamp
}
pub fn ended_timestamp(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.ended_timestamp = ::std::option::Option::Some(input);
self
}
pub fn set_ended_timestamp(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.ended_timestamp = input;
self
}
pub fn get_ended_timestamp(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.ended_timestamp
}
pub fn participants(mut self, input: crate::types::Participant) -> Self {
let mut v = self.participants.unwrap_or_default();
v.push(input);
self.participants = ::std::option::Option::Some(v);
self
}
pub fn set_participants(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Participant>>) -> Self {
self.participants = input;
self
}
pub fn get_participants(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Participant>> {
&self.participants
}
pub fn number_selection_behavior(mut self, input: crate::types::NumberSelectionBehavior) -> Self {
self.number_selection_behavior = ::std::option::Option::Some(input);
self
}
pub fn set_number_selection_behavior(mut self, input: ::std::option::Option<crate::types::NumberSelectionBehavior>) -> Self {
self.number_selection_behavior = input;
self
}
pub fn get_number_selection_behavior(&self) -> &::std::option::Option<crate::types::NumberSelectionBehavior> {
&self.number_selection_behavior
}
pub fn geo_match_level(mut self, input: crate::types::GeoMatchLevel) -> Self {
self.geo_match_level = ::std::option::Option::Some(input);
self
}
pub fn set_geo_match_level(mut self, input: ::std::option::Option<crate::types::GeoMatchLevel>) -> Self {
self.geo_match_level = input;
self
}
pub fn get_geo_match_level(&self) -> &::std::option::Option<crate::types::GeoMatchLevel> {
&self.geo_match_level
}
pub fn geo_match_params(mut self, input: crate::types::GeoMatchParams) -> Self {
self.geo_match_params = ::std::option::Option::Some(input);
self
}
pub fn set_geo_match_params(mut self, input: ::std::option::Option<crate::types::GeoMatchParams>) -> Self {
self.geo_match_params = input;
self
}
pub fn get_geo_match_params(&self) -> &::std::option::Option<crate::types::GeoMatchParams> {
&self.geo_match_params
}
pub fn build(self) -> crate::types::ProxySession {
crate::types::ProxySession {
voice_connector_id: self.voice_connector_id,
proxy_session_id: self.proxy_session_id,
name: self.name,
status: self.status,
expiry_minutes: self.expiry_minutes,
capabilities: self.capabilities,
created_timestamp: self.created_timestamp,
updated_timestamp: self.updated_timestamp,
ended_timestamp: self.ended_timestamp,
participants: self.participants,
number_selection_behavior: self.number_selection_behavior,
geo_match_level: self.geo_match_level,
geo_match_params: self.geo_match_params,
}
}
}