aws-sdk-location 0.26.0

AWS SDK for Amazon Location Service
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 GetMapTileInput {
    /// <p>The map resource to retrieve the map tiles from.</p>
    #[doc(hidden)]
    pub map_name: std::option::Option<std::string::String>,
    /// <p>The zoom value for the map tile.</p>
    #[doc(hidden)]
    pub z: std::option::Option<std::string::String>,
    /// <p>The X axis value for the map tile.</p>
    #[doc(hidden)]
    pub x: std::option::Option<std::string::String>,
    /// <p>The Y axis value for the map tile. </p>
    #[doc(hidden)]
    pub y: std::option::Option<std::string::String>,
    /// <p>The optional <a href="https://docs.aws.amazon.com/location/latest/developerguide/using-apikeys.html">API key</a> to authorize the request.</p>
    #[doc(hidden)]
    pub key: std::option::Option<std::string::String>,
}
impl GetMapTileInput {
    /// <p>The map resource to retrieve the map tiles from.</p>
    pub fn map_name(&self) -> std::option::Option<&str> {
        self.map_name.as_deref()
    }
    /// <p>The zoom value for the map tile.</p>
    pub fn z(&self) -> std::option::Option<&str> {
        self.z.as_deref()
    }
    /// <p>The X axis value for the map tile.</p>
    pub fn x(&self) -> std::option::Option<&str> {
        self.x.as_deref()
    }
    /// <p>The Y axis value for the map tile. </p>
    pub fn y(&self) -> std::option::Option<&str> {
        self.y.as_deref()
    }
    /// <p>The optional <a href="https://docs.aws.amazon.com/location/latest/developerguide/using-apikeys.html">API key</a> to authorize the request.</p>
    pub fn key(&self) -> std::option::Option<&str> {
        self.key.as_deref()
    }
}
impl std::fmt::Debug for GetMapTileInput {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        let mut formatter = f.debug_struct("GetMapTileInput");
        formatter.field("map_name", &self.map_name);
        formatter.field("z", &self.z);
        formatter.field("x", &self.x);
        formatter.field("y", &self.y);
        formatter.field("key", &"*** Sensitive Data Redacted ***");
        formatter.finish()
    }
}
impl GetMapTileInput {
    /// Creates a new builder-style object to manufacture [`GetMapTileInput`](crate::operation::get_map_tile::GetMapTileInput).
    pub fn builder() -> crate::operation::get_map_tile::builders::GetMapTileInputBuilder {
        crate::operation::get_map_tile::builders::GetMapTileInputBuilder::default()
    }
}

/// A builder for [`GetMapTileInput`](crate::operation::get_map_tile::GetMapTileInput).
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default)]
pub struct GetMapTileInputBuilder {
    pub(crate) map_name: std::option::Option<std::string::String>,
    pub(crate) z: std::option::Option<std::string::String>,
    pub(crate) x: std::option::Option<std::string::String>,
    pub(crate) y: std::option::Option<std::string::String>,
    pub(crate) key: std::option::Option<std::string::String>,
}
impl GetMapTileInputBuilder {
    /// <p>The map resource to retrieve the map tiles from.</p>
    pub fn map_name(mut self, input: impl Into<std::string::String>) -> Self {
        self.map_name = Some(input.into());
        self
    }
    /// <p>The map resource to retrieve the map tiles from.</p>
    pub fn set_map_name(mut self, input: std::option::Option<std::string::String>) -> Self {
        self.map_name = input;
        self
    }
    /// <p>The zoom value for the map tile.</p>
    pub fn z(mut self, input: impl Into<std::string::String>) -> Self {
        self.z = Some(input.into());
        self
    }
    /// <p>The zoom value for the map tile.</p>
    pub fn set_z(mut self, input: std::option::Option<std::string::String>) -> Self {
        self.z = input;
        self
    }
    /// <p>The X axis value for the map tile.</p>
    pub fn x(mut self, input: impl Into<std::string::String>) -> Self {
        self.x = Some(input.into());
        self
    }
    /// <p>The X axis value for the map tile.</p>
    pub fn set_x(mut self, input: std::option::Option<std::string::String>) -> Self {
        self.x = input;
        self
    }
    /// <p>The Y axis value for the map tile. </p>
    pub fn y(mut self, input: impl Into<std::string::String>) -> Self {
        self.y = Some(input.into());
        self
    }
    /// <p>The Y axis value for the map tile. </p>
    pub fn set_y(mut self, input: std::option::Option<std::string::String>) -> Self {
        self.y = input;
        self
    }
    /// <p>The optional <a href="https://docs.aws.amazon.com/location/latest/developerguide/using-apikeys.html">API key</a> to authorize the request.</p>
    pub fn key(mut self, input: impl Into<std::string::String>) -> Self {
        self.key = Some(input.into());
        self
    }
    /// <p>The optional <a href="https://docs.aws.amazon.com/location/latest/developerguide/using-apikeys.html">API key</a> to authorize the request.</p>
    pub fn set_key(mut self, input: std::option::Option<std::string::String>) -> Self {
        self.key = input;
        self
    }
    /// Consumes the builder and constructs a [`GetMapTileInput`](crate::operation::get_map_tile::GetMapTileInput).
    pub fn build(
        self,
    ) -> Result<
        crate::operation::get_map_tile::GetMapTileInput,
        aws_smithy_http::operation::error::BuildError,
    > {
        Ok(crate::operation::get_map_tile::GetMapTileInput {
            map_name: self.map_name,
            z: self.z,
            x: self.x,
            y: self.y,
            key: self.key,
        })
    }
}
impl std::fmt::Debug for GetMapTileInputBuilder {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        let mut formatter = f.debug_struct("GetMapTileInputBuilder");
        formatter.field("map_name", &self.map_name);
        formatter.field("z", &self.z);
        formatter.field("x", &self.x);
        formatter.field("y", &self.y);
        formatter.field("key", &"*** Sensitive Data Redacted ***");
        formatter.finish()
    }
}