aws-sdk-gamelift 1.119.0

AWS SDK for Amazon GameLift
Documentation
// 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)]
pub struct RegisterComputeInput {
    /// <p>A unique identifier for the fleet to register the compute to. You can use either the fleet ID or ARN value.</p>
    pub fleet_id: ::std::option::Option<::std::string::String>,
    /// <p>A descriptive label for the compute resource.</p>
    pub compute_name: ::std::option::Option<::std::string::String>,
    /// <p>The path to a TLS certificate on your compute resource. Amazon GameLift Servers doesn't validate the path and certificate.</p>
    pub certificate_path: ::std::option::Option<::std::string::String>,
    /// <p>The DNS name of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address.</p>
    pub dns_name: ::std::option::Option<::std::string::String>,
    /// <p>The IP address of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address. When registering an Anywhere fleet, an IP address is required.</p>
    pub ip_address: ::std::option::Option<::std::string::String>,
    /// <p>The name of a custom location to associate with the compute resource being registered. This parameter is required when registering a compute for an Anywhere fleet.</p>
    pub location: ::std::option::Option<::std::string::String>,
}
impl RegisterComputeInput {
    /// <p>A unique identifier for the fleet to register the compute to. You can use either the fleet ID or ARN value.</p>
    pub fn fleet_id(&self) -> ::std::option::Option<&str> {
        self.fleet_id.as_deref()
    }
    /// <p>A descriptive label for the compute resource.</p>
    pub fn compute_name(&self) -> ::std::option::Option<&str> {
        self.compute_name.as_deref()
    }
    /// <p>The path to a TLS certificate on your compute resource. Amazon GameLift Servers doesn't validate the path and certificate.</p>
    pub fn certificate_path(&self) -> ::std::option::Option<&str> {
        self.certificate_path.as_deref()
    }
    /// <p>The DNS name of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address.</p>
    pub fn dns_name(&self) -> ::std::option::Option<&str> {
        self.dns_name.as_deref()
    }
    /// <p>The IP address of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address. When registering an Anywhere fleet, an IP address is required.</p>
    pub fn ip_address(&self) -> ::std::option::Option<&str> {
        self.ip_address.as_deref()
    }
    /// <p>The name of a custom location to associate with the compute resource being registered. This parameter is required when registering a compute for an Anywhere fleet.</p>
    pub fn location(&self) -> ::std::option::Option<&str> {
        self.location.as_deref()
    }
}
impl ::std::fmt::Debug for RegisterComputeInput {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        let mut formatter = f.debug_struct("RegisterComputeInput");
        formatter.field("fleet_id", &self.fleet_id);
        formatter.field("compute_name", &self.compute_name);
        formatter.field("certificate_path", &self.certificate_path);
        formatter.field("dns_name", &self.dns_name);
        formatter.field("ip_address", &"*** Sensitive Data Redacted ***");
        formatter.field("location", &self.location);
        formatter.finish()
    }
}
impl RegisterComputeInput {
    /// Creates a new builder-style object to manufacture [`RegisterComputeInput`](crate::operation::register_compute::RegisterComputeInput).
    pub fn builder() -> crate::operation::register_compute::builders::RegisterComputeInputBuilder {
        crate::operation::register_compute::builders::RegisterComputeInputBuilder::default()
    }
}

/// A builder for [`RegisterComputeInput`](crate::operation::register_compute::RegisterComputeInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
#[non_exhaustive]
pub struct RegisterComputeInputBuilder {
    pub(crate) fleet_id: ::std::option::Option<::std::string::String>,
    pub(crate) compute_name: ::std::option::Option<::std::string::String>,
    pub(crate) certificate_path: ::std::option::Option<::std::string::String>,
    pub(crate) dns_name: ::std::option::Option<::std::string::String>,
    pub(crate) ip_address: ::std::option::Option<::std::string::String>,
    pub(crate) location: ::std::option::Option<::std::string::String>,
}
impl RegisterComputeInputBuilder {
    /// <p>A unique identifier for the fleet to register the compute to. You can use either the fleet ID or ARN value.</p>
    /// This field is required.
    pub fn fleet_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.fleet_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A unique identifier for the fleet to register the compute to. You can use either the fleet ID or ARN value.</p>
    pub fn set_fleet_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.fleet_id = input;
        self
    }
    /// <p>A unique identifier for the fleet to register the compute to. You can use either the fleet ID or ARN value.</p>
    pub fn get_fleet_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.fleet_id
    }
    /// <p>A descriptive label for the compute resource.</p>
    /// This field is required.
    pub fn compute_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.compute_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A descriptive label for the compute resource.</p>
    pub fn set_compute_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.compute_name = input;
        self
    }
    /// <p>A descriptive label for the compute resource.</p>
    pub fn get_compute_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.compute_name
    }
    /// <p>The path to a TLS certificate on your compute resource. Amazon GameLift Servers doesn't validate the path and certificate.</p>
    pub fn certificate_path(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.certificate_path = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The path to a TLS certificate on your compute resource. Amazon GameLift Servers doesn't validate the path and certificate.</p>
    pub fn set_certificate_path(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.certificate_path = input;
        self
    }
    /// <p>The path to a TLS certificate on your compute resource. Amazon GameLift Servers doesn't validate the path and certificate.</p>
    pub fn get_certificate_path(&self) -> &::std::option::Option<::std::string::String> {
        &self.certificate_path
    }
    /// <p>The DNS name of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address.</p>
    pub fn dns_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.dns_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The DNS name of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address.</p>
    pub fn set_dns_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.dns_name = input;
        self
    }
    /// <p>The DNS name of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address.</p>
    pub fn get_dns_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.dns_name
    }
    /// <p>The IP address of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address. When registering an Anywhere fleet, an IP address is required.</p>
    pub fn ip_address(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.ip_address = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The IP address of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address. When registering an Anywhere fleet, an IP address is required.</p>
    pub fn set_ip_address(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.ip_address = input;
        self
    }
    /// <p>The IP address of the compute resource. Amazon GameLift Servers requires either a DNS name or IP address. When registering an Anywhere fleet, an IP address is required.</p>
    pub fn get_ip_address(&self) -> &::std::option::Option<::std::string::String> {
        &self.ip_address
    }
    /// <p>The name of a custom location to associate with the compute resource being registered. This parameter is required when registering a compute for an Anywhere fleet.</p>
    pub fn location(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.location = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of a custom location to associate with the compute resource being registered. This parameter is required when registering a compute for an Anywhere fleet.</p>
    pub fn set_location(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.location = input;
        self
    }
    /// <p>The name of a custom location to associate with the compute resource being registered. This parameter is required when registering a compute for an Anywhere fleet.</p>
    pub fn get_location(&self) -> &::std::option::Option<::std::string::String> {
        &self.location
    }
    /// Consumes the builder and constructs a [`RegisterComputeInput`](crate::operation::register_compute::RegisterComputeInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::register_compute::RegisterComputeInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::register_compute::RegisterComputeInput {
            fleet_id: self.fleet_id,
            compute_name: self.compute_name,
            certificate_path: self.certificate_path,
            dns_name: self.dns_name,
            ip_address: self.ip_address,
            location: self.location,
        })
    }
}
impl ::std::fmt::Debug for RegisterComputeInputBuilder {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        let mut formatter = f.debug_struct("RegisterComputeInputBuilder");
        formatter.field("fleet_id", &self.fleet_id);
        formatter.field("compute_name", &self.compute_name);
        formatter.field("certificate_path", &self.certificate_path);
        formatter.field("dns_name", &self.dns_name);
        formatter.field("ip_address", &"*** Sensitive Data Redacted ***");
        formatter.field("location", &self.location);
        formatter.finish()
    }
}