1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct UpdateDomainInput {
/// <p>The ID of the domain to be updated.</p>
pub domain_id: ::std::option::Option<::std::string::String>,
/// <p>A collection of settings.</p>
pub default_user_settings: ::std::option::Option<crate::types::UserSettings>,
/// <p>A collection of <code>DomainSettings</code> configuration values to update.</p>
pub domain_settings_for_update: ::std::option::Option<crate::types::DomainSettingsForUpdate>,
/// <p>The default settings used to create a space within the Domain.</p>
pub default_space_settings: ::std::option::Option<crate::types::DefaultSpaceSettings>,
/// <p>The entity that creates and manages the required security groups for inter-app communication in <code>VPCOnly</code> mode. Required when <code>CreateDomain.AppNetworkAccessType</code> is <code>VPCOnly</code> and <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided. If setting up the domain for use with RStudio, this value must be set to <code>Service</code>.</p>
pub app_security_group_management: ::std::option::Option<crate::types::AppSecurityGroupManagement>,
/// <p>The VPC subnets that Studio uses for communication.</p>
/// <p>If removing subnets, ensure there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state.</p>
pub subnet_ids: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
/// <p>Specifies the VPC used for non-EFS traffic.</p>
/// <ul>
/// <li> <p> <code>PublicInternetOnly</code> - Non-EFS traffic is through a VPC managed by Amazon SageMaker, which allows direct internet access.</p> </li>
/// <li> <p> <code>VpcOnly</code> - All Studio traffic is through the specified VPC and subnets.</p> </li>
/// </ul>
/// <p>This configuration can only be modified if there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state. The configuration cannot be updated if <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is already set or <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided as part of the same request.</p>
pub app_network_access_type: ::std::option::Option<crate::types::AppNetworkAccessType>,
}
impl UpdateDomainInput {
/// <p>The ID of the domain to be updated.</p>
pub fn domain_id(&self) -> ::std::option::Option<&str> {
self.domain_id.as_deref()
}
/// <p>A collection of settings.</p>
pub fn default_user_settings(&self) -> ::std::option::Option<&crate::types::UserSettings> {
self.default_user_settings.as_ref()
}
/// <p>A collection of <code>DomainSettings</code> configuration values to update.</p>
pub fn domain_settings_for_update(&self) -> ::std::option::Option<&crate::types::DomainSettingsForUpdate> {
self.domain_settings_for_update.as_ref()
}
/// <p>The default settings used to create a space within the Domain.</p>
pub fn default_space_settings(&self) -> ::std::option::Option<&crate::types::DefaultSpaceSettings> {
self.default_space_settings.as_ref()
}
/// <p>The entity that creates and manages the required security groups for inter-app communication in <code>VPCOnly</code> mode. Required when <code>CreateDomain.AppNetworkAccessType</code> is <code>VPCOnly</code> and <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided. If setting up the domain for use with RStudio, this value must be set to <code>Service</code>.</p>
pub fn app_security_group_management(&self) -> ::std::option::Option<&crate::types::AppSecurityGroupManagement> {
self.app_security_group_management.as_ref()
}
/// <p>The VPC subnets that Studio uses for communication.</p>
/// <p>If removing subnets, ensure there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state.</p>
///
/// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.subnet_ids.is_none()`.
pub fn subnet_ids(&self) -> &[::std::string::String] {
self.subnet_ids.as_deref().unwrap_or_default()
}
/// <p>Specifies the VPC used for non-EFS traffic.</p>
/// <ul>
/// <li> <p> <code>PublicInternetOnly</code> - Non-EFS traffic is through a VPC managed by Amazon SageMaker, which allows direct internet access.</p> </li>
/// <li> <p> <code>VpcOnly</code> - All Studio traffic is through the specified VPC and subnets.</p> </li>
/// </ul>
/// <p>This configuration can only be modified if there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state. The configuration cannot be updated if <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is already set or <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided as part of the same request.</p>
pub fn app_network_access_type(&self) -> ::std::option::Option<&crate::types::AppNetworkAccessType> {
self.app_network_access_type.as_ref()
}
}
impl UpdateDomainInput {
/// Creates a new builder-style object to manufacture [`UpdateDomainInput`](crate::operation::update_domain::UpdateDomainInput).
pub fn builder() -> crate::operation::update_domain::builders::UpdateDomainInputBuilder {
crate::operation::update_domain::builders::UpdateDomainInputBuilder::default()
}
}
/// A builder for [`UpdateDomainInput`](crate::operation::update_domain::UpdateDomainInput).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct UpdateDomainInputBuilder {
pub(crate) domain_id: ::std::option::Option<::std::string::String>,
pub(crate) default_user_settings: ::std::option::Option<crate::types::UserSettings>,
pub(crate) domain_settings_for_update: ::std::option::Option<crate::types::DomainSettingsForUpdate>,
pub(crate) default_space_settings: ::std::option::Option<crate::types::DefaultSpaceSettings>,
pub(crate) app_security_group_management: ::std::option::Option<crate::types::AppSecurityGroupManagement>,
pub(crate) subnet_ids: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub(crate) app_network_access_type: ::std::option::Option<crate::types::AppNetworkAccessType>,
}
impl UpdateDomainInputBuilder {
/// <p>The ID of the domain to be updated.</p>
/// This field is required.
pub fn domain_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.domain_id = ::std::option::Option::Some(input.into());
self
}
/// <p>The ID of the domain to be updated.</p>
pub fn set_domain_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.domain_id = input;
self
}
/// <p>The ID of the domain to be updated.</p>
pub fn get_domain_id(&self) -> &::std::option::Option<::std::string::String> {
&self.domain_id
}
/// <p>A collection of settings.</p>
pub fn default_user_settings(mut self, input: crate::types::UserSettings) -> Self {
self.default_user_settings = ::std::option::Option::Some(input);
self
}
/// <p>A collection of settings.</p>
pub fn set_default_user_settings(mut self, input: ::std::option::Option<crate::types::UserSettings>) -> Self {
self.default_user_settings = input;
self
}
/// <p>A collection of settings.</p>
pub fn get_default_user_settings(&self) -> &::std::option::Option<crate::types::UserSettings> {
&self.default_user_settings
}
/// <p>A collection of <code>DomainSettings</code> configuration values to update.</p>
pub fn domain_settings_for_update(mut self, input: crate::types::DomainSettingsForUpdate) -> Self {
self.domain_settings_for_update = ::std::option::Option::Some(input);
self
}
/// <p>A collection of <code>DomainSettings</code> configuration values to update.</p>
pub fn set_domain_settings_for_update(mut self, input: ::std::option::Option<crate::types::DomainSettingsForUpdate>) -> Self {
self.domain_settings_for_update = input;
self
}
/// <p>A collection of <code>DomainSettings</code> configuration values to update.</p>
pub fn get_domain_settings_for_update(&self) -> &::std::option::Option<crate::types::DomainSettingsForUpdate> {
&self.domain_settings_for_update
}
/// <p>The default settings used to create a space within the Domain.</p>
pub fn default_space_settings(mut self, input: crate::types::DefaultSpaceSettings) -> Self {
self.default_space_settings = ::std::option::Option::Some(input);
self
}
/// <p>The default settings used to create a space within the Domain.</p>
pub fn set_default_space_settings(mut self, input: ::std::option::Option<crate::types::DefaultSpaceSettings>) -> Self {
self.default_space_settings = input;
self
}
/// <p>The default settings used to create a space within the Domain.</p>
pub fn get_default_space_settings(&self) -> &::std::option::Option<crate::types::DefaultSpaceSettings> {
&self.default_space_settings
}
/// <p>The entity that creates and manages the required security groups for inter-app communication in <code>VPCOnly</code> mode. Required when <code>CreateDomain.AppNetworkAccessType</code> is <code>VPCOnly</code> and <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided. If setting up the domain for use with RStudio, this value must be set to <code>Service</code>.</p>
pub fn app_security_group_management(mut self, input: crate::types::AppSecurityGroupManagement) -> Self {
self.app_security_group_management = ::std::option::Option::Some(input);
self
}
/// <p>The entity that creates and manages the required security groups for inter-app communication in <code>VPCOnly</code> mode. Required when <code>CreateDomain.AppNetworkAccessType</code> is <code>VPCOnly</code> and <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided. If setting up the domain for use with RStudio, this value must be set to <code>Service</code>.</p>
pub fn set_app_security_group_management(mut self, input: ::std::option::Option<crate::types::AppSecurityGroupManagement>) -> Self {
self.app_security_group_management = input;
self
}
/// <p>The entity that creates and manages the required security groups for inter-app communication in <code>VPCOnly</code> mode. Required when <code>CreateDomain.AppNetworkAccessType</code> is <code>VPCOnly</code> and <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided. If setting up the domain for use with RStudio, this value must be set to <code>Service</code>.</p>
pub fn get_app_security_group_management(&self) -> &::std::option::Option<crate::types::AppSecurityGroupManagement> {
&self.app_security_group_management
}
/// Appends an item to `subnet_ids`.
///
/// To override the contents of this collection use [`set_subnet_ids`](Self::set_subnet_ids).
///
/// <p>The VPC subnets that Studio uses for communication.</p>
/// <p>If removing subnets, ensure there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state.</p>
pub fn subnet_ids(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut v = self.subnet_ids.unwrap_or_default();
v.push(input.into());
self.subnet_ids = ::std::option::Option::Some(v);
self
}
/// <p>The VPC subnets that Studio uses for communication.</p>
/// <p>If removing subnets, ensure there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state.</p>
pub fn set_subnet_ids(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
self.subnet_ids = input;
self
}
/// <p>The VPC subnets that Studio uses for communication.</p>
/// <p>If removing subnets, ensure there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state.</p>
pub fn get_subnet_ids(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
&self.subnet_ids
}
/// <p>Specifies the VPC used for non-EFS traffic.</p>
/// <ul>
/// <li> <p> <code>PublicInternetOnly</code> - Non-EFS traffic is through a VPC managed by Amazon SageMaker, which allows direct internet access.</p> </li>
/// <li> <p> <code>VpcOnly</code> - All Studio traffic is through the specified VPC and subnets.</p> </li>
/// </ul>
/// <p>This configuration can only be modified if there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state. The configuration cannot be updated if <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is already set or <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided as part of the same request.</p>
pub fn app_network_access_type(mut self, input: crate::types::AppNetworkAccessType) -> Self {
self.app_network_access_type = ::std::option::Option::Some(input);
self
}
/// <p>Specifies the VPC used for non-EFS traffic.</p>
/// <ul>
/// <li> <p> <code>PublicInternetOnly</code> - Non-EFS traffic is through a VPC managed by Amazon SageMaker, which allows direct internet access.</p> </li>
/// <li> <p> <code>VpcOnly</code> - All Studio traffic is through the specified VPC and subnets.</p> </li>
/// </ul>
/// <p>This configuration can only be modified if there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state. The configuration cannot be updated if <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is already set or <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided as part of the same request.</p>
pub fn set_app_network_access_type(mut self, input: ::std::option::Option<crate::types::AppNetworkAccessType>) -> Self {
self.app_network_access_type = input;
self
}
/// <p>Specifies the VPC used for non-EFS traffic.</p>
/// <ul>
/// <li> <p> <code>PublicInternetOnly</code> - Non-EFS traffic is through a VPC managed by Amazon SageMaker, which allows direct internet access.</p> </li>
/// <li> <p> <code>VpcOnly</code> - All Studio traffic is through the specified VPC and subnets.</p> </li>
/// </ul>
/// <p>This configuration can only be modified if there are no apps in the <code>InService</code>, <code>Pending</code>, or <code>Deleting</code> state. The configuration cannot be updated if <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is already set or <code>DomainSettings.RStudioServerProDomainSettings.DomainExecutionRoleArn</code> is provided as part of the same request.</p>
pub fn get_app_network_access_type(&self) -> &::std::option::Option<crate::types::AppNetworkAccessType> {
&self.app_network_access_type
}
/// Consumes the builder and constructs a [`UpdateDomainInput`](crate::operation::update_domain::UpdateDomainInput).
pub fn build(
self,
) -> ::std::result::Result<crate::operation::update_domain::UpdateDomainInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::update_domain::UpdateDomainInput {
domain_id: self.domain_id,
default_user_settings: self.default_user_settings,
domain_settings_for_update: self.domain_settings_for_update,
default_space_settings: self.default_space_settings,
app_security_group_management: self.app_security_group_management,
subnet_ids: self.subnet_ids,
app_network_access_type: self.app_network_access_type,
})
}
}