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
// 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 DescribeServicesInput {
/// <p>The short name or full Amazon Resource Name (ARN)the cluster that hosts the service to describe. If you do not specify a cluster, the default cluster is assumed. This parameter is required if the service or services you are describing were launched in any cluster other than the default cluster.</p>
#[doc(hidden)]
pub cluster: std::option::Option<std::string::String>,
/// <p>A list of services to describe. You may specify up to 10 services to describe in a single operation.</p>
#[doc(hidden)]
pub services: std::option::Option<std::vec::Vec<std::string::String>>,
/// <p>Determines whether you want to see the resource tags for the service. If <code>TAGS</code> is specified, the tags are included in the response. If this field is omitted, tags aren't included in the response.</p>
#[doc(hidden)]
pub include: std::option::Option<std::vec::Vec<crate::types::ServiceField>>,
}
impl DescribeServicesInput {
/// <p>The short name or full Amazon Resource Name (ARN)the cluster that hosts the service to describe. If you do not specify a cluster, the default cluster is assumed. This parameter is required if the service or services you are describing were launched in any cluster other than the default cluster.</p>
pub fn cluster(&self) -> std::option::Option<&str> {
self.cluster.as_deref()
}
/// <p>A list of services to describe. You may specify up to 10 services to describe in a single operation.</p>
pub fn services(&self) -> std::option::Option<&[std::string::String]> {
self.services.as_deref()
}
/// <p>Determines whether you want to see the resource tags for the service. If <code>TAGS</code> is specified, the tags are included in the response. If this field is omitted, tags aren't included in the response.</p>
pub fn include(&self) -> std::option::Option<&[crate::types::ServiceField]> {
self.include.as_deref()
}
}
impl DescribeServicesInput {
/// Creates a new builder-style object to manufacture [`DescribeServicesInput`](crate::operation::describe_services::DescribeServicesInput).
pub fn builder() -> crate::operation::describe_services::builders::DescribeServicesInputBuilder
{
crate::operation::describe_services::builders::DescribeServicesInputBuilder::default()
}
}
/// A builder for [`DescribeServicesInput`](crate::operation::describe_services::DescribeServicesInput).
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct DescribeServicesInputBuilder {
pub(crate) cluster: std::option::Option<std::string::String>,
pub(crate) services: std::option::Option<std::vec::Vec<std::string::String>>,
pub(crate) include: std::option::Option<std::vec::Vec<crate::types::ServiceField>>,
}
impl DescribeServicesInputBuilder {
/// <p>The short name or full Amazon Resource Name (ARN)the cluster that hosts the service to describe. If you do not specify a cluster, the default cluster is assumed. This parameter is required if the service or services you are describing were launched in any cluster other than the default cluster.</p>
pub fn cluster(mut self, input: impl Into<std::string::String>) -> Self {
self.cluster = Some(input.into());
self
}
/// <p>The short name or full Amazon Resource Name (ARN)the cluster that hosts the service to describe. If you do not specify a cluster, the default cluster is assumed. This parameter is required if the service or services you are describing were launched in any cluster other than the default cluster.</p>
pub fn set_cluster(mut self, input: std::option::Option<std::string::String>) -> Self {
self.cluster = input;
self
}
/// Appends an item to `services`.
///
/// To override the contents of this collection use [`set_services`](Self::set_services).
///
/// <p>A list of services to describe. You may specify up to 10 services to describe in a single operation.</p>
pub fn services(mut self, input: impl Into<std::string::String>) -> Self {
let mut v = self.services.unwrap_or_default();
v.push(input.into());
self.services = Some(v);
self
}
/// <p>A list of services to describe. You may specify up to 10 services to describe in a single operation.</p>
pub fn set_services(
mut self,
input: std::option::Option<std::vec::Vec<std::string::String>>,
) -> Self {
self.services = input;
self
}
/// Appends an item to `include`.
///
/// To override the contents of this collection use [`set_include`](Self::set_include).
///
/// <p>Determines whether you want to see the resource tags for the service. If <code>TAGS</code> is specified, the tags are included in the response. If this field is omitted, tags aren't included in the response.</p>
pub fn include(mut self, input: crate::types::ServiceField) -> Self {
let mut v = self.include.unwrap_or_default();
v.push(input);
self.include = Some(v);
self
}
/// <p>Determines whether you want to see the resource tags for the service. If <code>TAGS</code> is specified, the tags are included in the response. If this field is omitted, tags aren't included in the response.</p>
pub fn set_include(
mut self,
input: std::option::Option<std::vec::Vec<crate::types::ServiceField>>,
) -> Self {
self.include = input;
self
}
/// Consumes the builder and constructs a [`DescribeServicesInput`](crate::operation::describe_services::DescribeServicesInput).
pub fn build(
self,
) -> Result<
crate::operation::describe_services::DescribeServicesInput,
aws_smithy_http::operation::error::BuildError,
> {
Ok(crate::operation::describe_services::DescribeServicesInput {
cluster: self.cluster,
services: self.services,
include: self.include,
})
}
}