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 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// <p>Describes the Amazon FSx for NetApp ONTAP storage virtual machine (SVM) configuration.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct StorageVirtualMachine {
/// <p>Describes the Microsoft Active Directory configuration to which the SVM is joined, if applicable.</p>
pub active_directory_configuration: ::std::option::Option<crate::types::SvmActiveDirectoryConfiguration>,
/// <p>The time that the resource was created, in seconds (since 1970-01-01T00:00:00Z), also known as Unix time.</p>
pub creation_time: ::std::option::Option<::aws_smithy_types::DateTime>,
/// <p>The endpoints that are used to access data or to manage the SVM using the NetApp ONTAP CLI, REST API, or NetApp CloudManager. They are the <code>Iscsi</code>, <code>Management</code>, <code>Nfs</code>, and <code>Smb</code> endpoints.</p>
pub endpoints: ::std::option::Option<crate::types::SvmEndpoints>,
/// <p>The globally unique ID of the file system, assigned by Amazon FSx.</p>
pub file_system_id: ::std::option::Option<::std::string::String>,
/// <p>Describes the SVM's lifecycle status.</p>
/// <ul>
/// <li>
/// <p><code>CREATED</code> - The SVM is fully available for use.</p></li>
/// <li>
/// <p><code>CREATING</code> - Amazon FSx is creating the new SVM.</p></li>
/// <li>
/// <p><code>DELETING</code> - Amazon FSx is deleting an existing SVM.</p></li>
/// <li>
/// <p><code>FAILED</code> - Amazon FSx was unable to create the SVM.</p></li>
/// <li>
/// <p><code>MISCONFIGURED</code> - The SVM is in a failed but recoverable state.</p></li>
/// <li>
/// <p><code>PENDING</code> - Amazon FSx has not started creating the SVM.</p></li>
/// </ul>
pub lifecycle: ::std::option::Option<crate::types::StorageVirtualMachineLifecycle>,
/// <p>The name of the SVM, if provisioned.</p>
pub name: ::std::option::Option<::std::string::String>,
/// <p>The Amazon Resource Name (ARN) for a given resource. ARNs uniquely identify Amazon Web Services resources. We require an ARN when you need to specify a resource unambiguously across all of Amazon Web Services. For more information, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs)</a> in the <i>Amazon Web Services General Reference</i>.</p>
pub resource_arn: ::std::option::Option<::std::string::String>,
/// <p>The SVM's system generated unique ID.</p>
pub storage_virtual_machine_id: ::std::option::Option<::std::string::String>,
/// <p>Describes the SVM's subtype.</p>
pub subtype: ::std::option::Option<crate::types::StorageVirtualMachineSubtype>,
/// <p>The SVM's UUID (universally unique identifier).</p>
pub uuid: ::std::option::Option<::std::string::String>,
/// <p>A list of <code>Tag</code> values, with a maximum of 50 elements.</p>
pub tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
/// <p>Describes why the SVM lifecycle state changed.</p>
pub lifecycle_transition_reason: ::std::option::Option<crate::types::LifecycleTransitionReason>,
/// <p>The security style of the root volume of the SVM.</p>
pub root_volume_security_style: ::std::option::Option<crate::types::StorageVirtualMachineRootVolumeSecurityStyle>,
}
impl StorageVirtualMachine {
/// <p>Describes the Microsoft Active Directory configuration to which the SVM is joined, if applicable.</p>
pub fn active_directory_configuration(&self) -> ::std::option::Option<&crate::types::SvmActiveDirectoryConfiguration> {
self.active_directory_configuration.as_ref()
}
/// <p>The time that the resource was created, in seconds (since 1970-01-01T00:00:00Z), also known as Unix time.</p>
pub fn creation_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.creation_time.as_ref()
}
/// <p>The endpoints that are used to access data or to manage the SVM using the NetApp ONTAP CLI, REST API, or NetApp CloudManager. They are the <code>Iscsi</code>, <code>Management</code>, <code>Nfs</code>, and <code>Smb</code> endpoints.</p>
pub fn endpoints(&self) -> ::std::option::Option<&crate::types::SvmEndpoints> {
self.endpoints.as_ref()
}
/// <p>The globally unique ID of the file system, assigned by Amazon FSx.</p>
pub fn file_system_id(&self) -> ::std::option::Option<&str> {
self.file_system_id.as_deref()
}
/// <p>Describes the SVM's lifecycle status.</p>
/// <ul>
/// <li>
/// <p><code>CREATED</code> - The SVM is fully available for use.</p></li>
/// <li>
/// <p><code>CREATING</code> - Amazon FSx is creating the new SVM.</p></li>
/// <li>
/// <p><code>DELETING</code> - Amazon FSx is deleting an existing SVM.</p></li>
/// <li>
/// <p><code>FAILED</code> - Amazon FSx was unable to create the SVM.</p></li>
/// <li>
/// <p><code>MISCONFIGURED</code> - The SVM is in a failed but recoverable state.</p></li>
/// <li>
/// <p><code>PENDING</code> - Amazon FSx has not started creating the SVM.</p></li>
/// </ul>
pub fn lifecycle(&self) -> ::std::option::Option<&crate::types::StorageVirtualMachineLifecycle> {
self.lifecycle.as_ref()
}
/// <p>The name of the SVM, if provisioned.</p>
pub fn name(&self) -> ::std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The Amazon Resource Name (ARN) for a given resource. ARNs uniquely identify Amazon Web Services resources. We require an ARN when you need to specify a resource unambiguously across all of Amazon Web Services. For more information, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs)</a> in the <i>Amazon Web Services General Reference</i>.</p>
pub fn resource_arn(&self) -> ::std::option::Option<&str> {
self.resource_arn.as_deref()
}
/// <p>The SVM's system generated unique ID.</p>
pub fn storage_virtual_machine_id(&self) -> ::std::option::Option<&str> {
self.storage_virtual_machine_id.as_deref()
}
/// <p>Describes the SVM's subtype.</p>
pub fn subtype(&self) -> ::std::option::Option<&crate::types::StorageVirtualMachineSubtype> {
self.subtype.as_ref()
}
/// <p>The SVM's UUID (universally unique identifier).</p>
pub fn uuid(&self) -> ::std::option::Option<&str> {
self.uuid.as_deref()
}
/// <p>A list of <code>Tag</code> values, with a maximum of 50 elements.</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 `.tags.is_none()`.
pub fn tags(&self) -> &[crate::types::Tag] {
self.tags.as_deref().unwrap_or_default()
}
/// <p>Describes why the SVM lifecycle state changed.</p>
pub fn lifecycle_transition_reason(&self) -> ::std::option::Option<&crate::types::LifecycleTransitionReason> {
self.lifecycle_transition_reason.as_ref()
}
/// <p>The security style of the root volume of the SVM.</p>
pub fn root_volume_security_style(&self) -> ::std::option::Option<&crate::types::StorageVirtualMachineRootVolumeSecurityStyle> {
self.root_volume_security_style.as_ref()
}
}
impl StorageVirtualMachine {
/// Creates a new builder-style object to manufacture [`StorageVirtualMachine`](crate::types::StorageVirtualMachine).
pub fn builder() -> crate::types::builders::StorageVirtualMachineBuilder {
crate::types::builders::StorageVirtualMachineBuilder::default()
}
}
/// A builder for [`StorageVirtualMachine`](crate::types::StorageVirtualMachine).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct StorageVirtualMachineBuilder {
pub(crate) active_directory_configuration: ::std::option::Option<crate::types::SvmActiveDirectoryConfiguration>,
pub(crate) creation_time: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) endpoints: ::std::option::Option<crate::types::SvmEndpoints>,
pub(crate) file_system_id: ::std::option::Option<::std::string::String>,
pub(crate) lifecycle: ::std::option::Option<crate::types::StorageVirtualMachineLifecycle>,
pub(crate) name: ::std::option::Option<::std::string::String>,
pub(crate) resource_arn: ::std::option::Option<::std::string::String>,
pub(crate) storage_virtual_machine_id: ::std::option::Option<::std::string::String>,
pub(crate) subtype: ::std::option::Option<crate::types::StorageVirtualMachineSubtype>,
pub(crate) uuid: ::std::option::Option<::std::string::String>,
pub(crate) tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
pub(crate) lifecycle_transition_reason: ::std::option::Option<crate::types::LifecycleTransitionReason>,
pub(crate) root_volume_security_style: ::std::option::Option<crate::types::StorageVirtualMachineRootVolumeSecurityStyle>,
}
impl StorageVirtualMachineBuilder {
/// <p>Describes the Microsoft Active Directory configuration to which the SVM is joined, if applicable.</p>
pub fn active_directory_configuration(mut self, input: crate::types::SvmActiveDirectoryConfiguration) -> Self {
self.active_directory_configuration = ::std::option::Option::Some(input);
self
}
/// <p>Describes the Microsoft Active Directory configuration to which the SVM is joined, if applicable.</p>
pub fn set_active_directory_configuration(mut self, input: ::std::option::Option<crate::types::SvmActiveDirectoryConfiguration>) -> Self {
self.active_directory_configuration = input;
self
}
/// <p>Describes the Microsoft Active Directory configuration to which the SVM is joined, if applicable.</p>
pub fn get_active_directory_configuration(&self) -> &::std::option::Option<crate::types::SvmActiveDirectoryConfiguration> {
&self.active_directory_configuration
}
/// <p>The time that the resource was created, in seconds (since 1970-01-01T00:00:00Z), also known as Unix time.</p>
pub fn creation_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.creation_time = ::std::option::Option::Some(input);
self
}
/// <p>The time that the resource was created, in seconds (since 1970-01-01T00:00:00Z), also known as Unix time.</p>
pub fn set_creation_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.creation_time = input;
self
}
/// <p>The time that the resource was created, in seconds (since 1970-01-01T00:00:00Z), also known as Unix time.</p>
pub fn get_creation_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.creation_time
}
/// <p>The endpoints that are used to access data or to manage the SVM using the NetApp ONTAP CLI, REST API, or NetApp CloudManager. They are the <code>Iscsi</code>, <code>Management</code>, <code>Nfs</code>, and <code>Smb</code> endpoints.</p>
pub fn endpoints(mut self, input: crate::types::SvmEndpoints) -> Self {
self.endpoints = ::std::option::Option::Some(input);
self
}
/// <p>The endpoints that are used to access data or to manage the SVM using the NetApp ONTAP CLI, REST API, or NetApp CloudManager. They are the <code>Iscsi</code>, <code>Management</code>, <code>Nfs</code>, and <code>Smb</code> endpoints.</p>
pub fn set_endpoints(mut self, input: ::std::option::Option<crate::types::SvmEndpoints>) -> Self {
self.endpoints = input;
self
}
/// <p>The endpoints that are used to access data or to manage the SVM using the NetApp ONTAP CLI, REST API, or NetApp CloudManager. They are the <code>Iscsi</code>, <code>Management</code>, <code>Nfs</code>, and <code>Smb</code> endpoints.</p>
pub fn get_endpoints(&self) -> &::std::option::Option<crate::types::SvmEndpoints> {
&self.endpoints
}
/// <p>The globally unique ID of the file system, assigned by Amazon FSx.</p>
pub fn file_system_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.file_system_id = ::std::option::Option::Some(input.into());
self
}
/// <p>The globally unique ID of the file system, assigned by Amazon FSx.</p>
pub fn set_file_system_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.file_system_id = input;
self
}
/// <p>The globally unique ID of the file system, assigned by Amazon FSx.</p>
pub fn get_file_system_id(&self) -> &::std::option::Option<::std::string::String> {
&self.file_system_id
}
/// <p>Describes the SVM's lifecycle status.</p>
/// <ul>
/// <li>
/// <p><code>CREATED</code> - The SVM is fully available for use.</p></li>
/// <li>
/// <p><code>CREATING</code> - Amazon FSx is creating the new SVM.</p></li>
/// <li>
/// <p><code>DELETING</code> - Amazon FSx is deleting an existing SVM.</p></li>
/// <li>
/// <p><code>FAILED</code> - Amazon FSx was unable to create the SVM.</p></li>
/// <li>
/// <p><code>MISCONFIGURED</code> - The SVM is in a failed but recoverable state.</p></li>
/// <li>
/// <p><code>PENDING</code> - Amazon FSx has not started creating the SVM.</p></li>
/// </ul>
pub fn lifecycle(mut self, input: crate::types::StorageVirtualMachineLifecycle) -> Self {
self.lifecycle = ::std::option::Option::Some(input);
self
}
/// <p>Describes the SVM's lifecycle status.</p>
/// <ul>
/// <li>
/// <p><code>CREATED</code> - The SVM is fully available for use.</p></li>
/// <li>
/// <p><code>CREATING</code> - Amazon FSx is creating the new SVM.</p></li>
/// <li>
/// <p><code>DELETING</code> - Amazon FSx is deleting an existing SVM.</p></li>
/// <li>
/// <p><code>FAILED</code> - Amazon FSx was unable to create the SVM.</p></li>
/// <li>
/// <p><code>MISCONFIGURED</code> - The SVM is in a failed but recoverable state.</p></li>
/// <li>
/// <p><code>PENDING</code> - Amazon FSx has not started creating the SVM.</p></li>
/// </ul>
pub fn set_lifecycle(mut self, input: ::std::option::Option<crate::types::StorageVirtualMachineLifecycle>) -> Self {
self.lifecycle = input;
self
}
/// <p>Describes the SVM's lifecycle status.</p>
/// <ul>
/// <li>
/// <p><code>CREATED</code> - The SVM is fully available for use.</p></li>
/// <li>
/// <p><code>CREATING</code> - Amazon FSx is creating the new SVM.</p></li>
/// <li>
/// <p><code>DELETING</code> - Amazon FSx is deleting an existing SVM.</p></li>
/// <li>
/// <p><code>FAILED</code> - Amazon FSx was unable to create the SVM.</p></li>
/// <li>
/// <p><code>MISCONFIGURED</code> - The SVM is in a failed but recoverable state.</p></li>
/// <li>
/// <p><code>PENDING</code> - Amazon FSx has not started creating the SVM.</p></li>
/// </ul>
pub fn get_lifecycle(&self) -> &::std::option::Option<crate::types::StorageVirtualMachineLifecycle> {
&self.lifecycle
}
/// <p>The name of the SVM, if provisioned.</p>
pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.name = ::std::option::Option::Some(input.into());
self
}
/// <p>The name of the SVM, if provisioned.</p>
pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The name of the SVM, if provisioned.</p>
pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
&self.name
}
/// <p>The Amazon Resource Name (ARN) for a given resource. ARNs uniquely identify Amazon Web Services resources. We require an ARN when you need to specify a resource unambiguously across all of Amazon Web Services. For more information, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs)</a> in the <i>Amazon Web Services General Reference</i>.</p>
pub fn resource_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.resource_arn = ::std::option::Option::Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) for a given resource. ARNs uniquely identify Amazon Web Services resources. We require an ARN when you need to specify a resource unambiguously across all of Amazon Web Services. For more information, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs)</a> in the <i>Amazon Web Services General Reference</i>.</p>
pub fn set_resource_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.resource_arn = input;
self
}
/// <p>The Amazon Resource Name (ARN) for a given resource. ARNs uniquely identify Amazon Web Services resources. We require an ARN when you need to specify a resource unambiguously across all of Amazon Web Services. For more information, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs)</a> in the <i>Amazon Web Services General Reference</i>.</p>
pub fn get_resource_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.resource_arn
}
/// <p>The SVM's system generated unique ID.</p>
pub fn storage_virtual_machine_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.storage_virtual_machine_id = ::std::option::Option::Some(input.into());
self
}
/// <p>The SVM's system generated unique ID.</p>
pub fn set_storage_virtual_machine_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.storage_virtual_machine_id = input;
self
}
/// <p>The SVM's system generated unique ID.</p>
pub fn get_storage_virtual_machine_id(&self) -> &::std::option::Option<::std::string::String> {
&self.storage_virtual_machine_id
}
/// <p>Describes the SVM's subtype.</p>
pub fn subtype(mut self, input: crate::types::StorageVirtualMachineSubtype) -> Self {
self.subtype = ::std::option::Option::Some(input);
self
}
/// <p>Describes the SVM's subtype.</p>
pub fn set_subtype(mut self, input: ::std::option::Option<crate::types::StorageVirtualMachineSubtype>) -> Self {
self.subtype = input;
self
}
/// <p>Describes the SVM's subtype.</p>
pub fn get_subtype(&self) -> &::std::option::Option<crate::types::StorageVirtualMachineSubtype> {
&self.subtype
}
/// <p>The SVM's UUID (universally unique identifier).</p>
pub fn uuid(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.uuid = ::std::option::Option::Some(input.into());
self
}
/// <p>The SVM's UUID (universally unique identifier).</p>
pub fn set_uuid(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.uuid = input;
self
}
/// <p>The SVM's UUID (universally unique identifier).</p>
pub fn get_uuid(&self) -> &::std::option::Option<::std::string::String> {
&self.uuid
}
/// Appends an item to `tags`.
///
/// To override the contents of this collection use [`set_tags`](Self::set_tags).
///
/// <p>A list of <code>Tag</code> values, with a maximum of 50 elements.</p>
pub fn tags(mut self, input: crate::types::Tag) -> Self {
let mut v = self.tags.unwrap_or_default();
v.push(input);
self.tags = ::std::option::Option::Some(v);
self
}
/// <p>A list of <code>Tag</code> values, with a maximum of 50 elements.</p>
pub fn set_tags(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>) -> Self {
self.tags = input;
self
}
/// <p>A list of <code>Tag</code> values, with a maximum of 50 elements.</p>
pub fn get_tags(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Tag>> {
&self.tags
}
/// <p>Describes why the SVM lifecycle state changed.</p>
pub fn lifecycle_transition_reason(mut self, input: crate::types::LifecycleTransitionReason) -> Self {
self.lifecycle_transition_reason = ::std::option::Option::Some(input);
self
}
/// <p>Describes why the SVM lifecycle state changed.</p>
pub fn set_lifecycle_transition_reason(mut self, input: ::std::option::Option<crate::types::LifecycleTransitionReason>) -> Self {
self.lifecycle_transition_reason = input;
self
}
/// <p>Describes why the SVM lifecycle state changed.</p>
pub fn get_lifecycle_transition_reason(&self) -> &::std::option::Option<crate::types::LifecycleTransitionReason> {
&self.lifecycle_transition_reason
}
/// <p>The security style of the root volume of the SVM.</p>
pub fn root_volume_security_style(mut self, input: crate::types::StorageVirtualMachineRootVolumeSecurityStyle) -> Self {
self.root_volume_security_style = ::std::option::Option::Some(input);
self
}
/// <p>The security style of the root volume of the SVM.</p>
pub fn set_root_volume_security_style(
mut self,
input: ::std::option::Option<crate::types::StorageVirtualMachineRootVolumeSecurityStyle>,
) -> Self {
self.root_volume_security_style = input;
self
}
/// <p>The security style of the root volume of the SVM.</p>
pub fn get_root_volume_security_style(&self) -> &::std::option::Option<crate::types::StorageVirtualMachineRootVolumeSecurityStyle> {
&self.root_volume_security_style
}
/// Consumes the builder and constructs a [`StorageVirtualMachine`](crate::types::StorageVirtualMachine).
pub fn build(self) -> crate::types::StorageVirtualMachine {
crate::types::StorageVirtualMachine {
active_directory_configuration: self.active_directory_configuration,
creation_time: self.creation_time,
endpoints: self.endpoints,
file_system_id: self.file_system_id,
lifecycle: self.lifecycle,
name: self.name,
resource_arn: self.resource_arn,
storage_virtual_machine_id: self.storage_virtual_machine_id,
subtype: self.subtype,
uuid: self.uuid,
tags: self.tags,
lifecycle_transition_reason: self.lifecycle_transition_reason,
root_volume_security_style: self.root_volume_security_style,
}
}
}