aws-sdk-iottwinmaker 1.101.0

AWS SDK for AWS IoT TwinMaker
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, ::std::fmt::Debug)]
pub struct GetPropertyValueInput {
    /// <p>The name of the component whose property values the operation returns.</p>
    pub component_name: ::std::option::Option<::std::string::String>,
    /// <p>This string specifies the path to the composite component, starting from the top-level component.</p>
    pub component_path: ::std::option::Option<::std::string::String>,
    /// <p>The ID of the component type whose property values the operation returns.</p>
    pub component_type_id: ::std::option::Option<::std::string::String>,
    /// <p>The ID of the entity whose property values the operation returns.</p>
    pub entity_id: ::std::option::Option<::std::string::String>,
    /// <p>The properties whose values the operation returns.</p>
    pub selected_properties: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
    /// <p>The ID of the workspace whose values the operation returns.</p>
    pub workspace_id: ::std::option::Option<::std::string::String>,
    /// <p>The maximum number of results to return at one time. The default is 25.</p>
    /// <p>Valid Range: Minimum value of 1. Maximum value of 250.</p>
    pub max_results: ::std::option::Option<i32>,
    /// <p>The string that specifies the next page of results.</p>
    pub next_token: ::std::option::Option<::std::string::String>,
    /// <p>The property group name.</p>
    pub property_group_name: ::std::option::Option<::std::string::String>,
    /// <p>The tabular conditions.</p>
    pub tabular_conditions: ::std::option::Option<crate::types::TabularConditions>,
}
impl GetPropertyValueInput {
    /// <p>The name of the component whose property values the operation returns.</p>
    pub fn component_name(&self) -> ::std::option::Option<&str> {
        self.component_name.as_deref()
    }
    /// <p>This string specifies the path to the composite component, starting from the top-level component.</p>
    pub fn component_path(&self) -> ::std::option::Option<&str> {
        self.component_path.as_deref()
    }
    /// <p>The ID of the component type whose property values the operation returns.</p>
    pub fn component_type_id(&self) -> ::std::option::Option<&str> {
        self.component_type_id.as_deref()
    }
    /// <p>The ID of the entity whose property values the operation returns.</p>
    pub fn entity_id(&self) -> ::std::option::Option<&str> {
        self.entity_id.as_deref()
    }
    /// <p>The properties whose values the operation returns.</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 `.selected_properties.is_none()`.
    pub fn selected_properties(&self) -> &[::std::string::String] {
        self.selected_properties.as_deref().unwrap_or_default()
    }
    /// <p>The ID of the workspace whose values the operation returns.</p>
    pub fn workspace_id(&self) -> ::std::option::Option<&str> {
        self.workspace_id.as_deref()
    }
    /// <p>The maximum number of results to return at one time. The default is 25.</p>
    /// <p>Valid Range: Minimum value of 1. Maximum value of 250.</p>
    pub fn max_results(&self) -> ::std::option::Option<i32> {
        self.max_results
    }
    /// <p>The string that specifies the next page of results.</p>
    pub fn next_token(&self) -> ::std::option::Option<&str> {
        self.next_token.as_deref()
    }
    /// <p>The property group name.</p>
    pub fn property_group_name(&self) -> ::std::option::Option<&str> {
        self.property_group_name.as_deref()
    }
    /// <p>The tabular conditions.</p>
    pub fn tabular_conditions(&self) -> ::std::option::Option<&crate::types::TabularConditions> {
        self.tabular_conditions.as_ref()
    }
}
impl GetPropertyValueInput {
    /// Creates a new builder-style object to manufacture [`GetPropertyValueInput`](crate::operation::get_property_value::GetPropertyValueInput).
    pub fn builder() -> crate::operation::get_property_value::builders::GetPropertyValueInputBuilder {
        crate::operation::get_property_value::builders::GetPropertyValueInputBuilder::default()
    }
}

/// A builder for [`GetPropertyValueInput`](crate::operation::get_property_value::GetPropertyValueInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetPropertyValueInputBuilder {
    pub(crate) component_name: ::std::option::Option<::std::string::String>,
    pub(crate) component_path: ::std::option::Option<::std::string::String>,
    pub(crate) component_type_id: ::std::option::Option<::std::string::String>,
    pub(crate) entity_id: ::std::option::Option<::std::string::String>,
    pub(crate) selected_properties: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
    pub(crate) workspace_id: ::std::option::Option<::std::string::String>,
    pub(crate) max_results: ::std::option::Option<i32>,
    pub(crate) next_token: ::std::option::Option<::std::string::String>,
    pub(crate) property_group_name: ::std::option::Option<::std::string::String>,
    pub(crate) tabular_conditions: ::std::option::Option<crate::types::TabularConditions>,
}
impl GetPropertyValueInputBuilder {
    /// <p>The name of the component whose property values the operation returns.</p>
    pub fn component_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.component_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of the component whose property values the operation returns.</p>
    pub fn set_component_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.component_name = input;
        self
    }
    /// <p>The name of the component whose property values the operation returns.</p>
    pub fn get_component_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.component_name
    }
    /// <p>This string specifies the path to the composite component, starting from the top-level component.</p>
    pub fn component_path(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.component_path = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>This string specifies the path to the composite component, starting from the top-level component.</p>
    pub fn set_component_path(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.component_path = input;
        self
    }
    /// <p>This string specifies the path to the composite component, starting from the top-level component.</p>
    pub fn get_component_path(&self) -> &::std::option::Option<::std::string::String> {
        &self.component_path
    }
    /// <p>The ID of the component type whose property values the operation returns.</p>
    pub fn component_type_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.component_type_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the component type whose property values the operation returns.</p>
    pub fn set_component_type_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.component_type_id = input;
        self
    }
    /// <p>The ID of the component type whose property values the operation returns.</p>
    pub fn get_component_type_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.component_type_id
    }
    /// <p>The ID of the entity whose property values the operation returns.</p>
    pub fn entity_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.entity_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the entity whose property values the operation returns.</p>
    pub fn set_entity_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.entity_id = input;
        self
    }
    /// <p>The ID of the entity whose property values the operation returns.</p>
    pub fn get_entity_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.entity_id
    }
    /// Appends an item to `selected_properties`.
    ///
    /// To override the contents of this collection use [`set_selected_properties`](Self::set_selected_properties).
    ///
    /// <p>The properties whose values the operation returns.</p>
    pub fn selected_properties(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        let mut v = self.selected_properties.unwrap_or_default();
        v.push(input.into());
        self.selected_properties = ::std::option::Option::Some(v);
        self
    }
    /// <p>The properties whose values the operation returns.</p>
    pub fn set_selected_properties(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
        self.selected_properties = input;
        self
    }
    /// <p>The properties whose values the operation returns.</p>
    pub fn get_selected_properties(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
        &self.selected_properties
    }
    /// <p>The ID of the workspace whose values the operation returns.</p>
    /// This field is required.
    pub fn workspace_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.workspace_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the workspace whose values the operation returns.</p>
    pub fn set_workspace_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.workspace_id = input;
        self
    }
    /// <p>The ID of the workspace whose values the operation returns.</p>
    pub fn get_workspace_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.workspace_id
    }
    /// <p>The maximum number of results to return at one time. The default is 25.</p>
    /// <p>Valid Range: Minimum value of 1. Maximum value of 250.</p>
    pub fn max_results(mut self, input: i32) -> Self {
        self.max_results = ::std::option::Option::Some(input);
        self
    }
    /// <p>The maximum number of results to return at one time. The default is 25.</p>
    /// <p>Valid Range: Minimum value of 1. Maximum value of 250.</p>
    pub fn set_max_results(mut self, input: ::std::option::Option<i32>) -> Self {
        self.max_results = input;
        self
    }
    /// <p>The maximum number of results to return at one time. The default is 25.</p>
    /// <p>Valid Range: Minimum value of 1. Maximum value of 250.</p>
    pub fn get_max_results(&self) -> &::std::option::Option<i32> {
        &self.max_results
    }
    /// <p>The string that specifies the next page of results.</p>
    pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.next_token = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The string that specifies the next page of results.</p>
    pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.next_token = input;
        self
    }
    /// <p>The string that specifies the next page of results.</p>
    pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
        &self.next_token
    }
    /// <p>The property group name.</p>
    pub fn property_group_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.property_group_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The property group name.</p>
    pub fn set_property_group_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.property_group_name = input;
        self
    }
    /// <p>The property group name.</p>
    pub fn get_property_group_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.property_group_name
    }
    /// <p>The tabular conditions.</p>
    pub fn tabular_conditions(mut self, input: crate::types::TabularConditions) -> Self {
        self.tabular_conditions = ::std::option::Option::Some(input);
        self
    }
    /// <p>The tabular conditions.</p>
    pub fn set_tabular_conditions(mut self, input: ::std::option::Option<crate::types::TabularConditions>) -> Self {
        self.tabular_conditions = input;
        self
    }
    /// <p>The tabular conditions.</p>
    pub fn get_tabular_conditions(&self) -> &::std::option::Option<crate::types::TabularConditions> {
        &self.tabular_conditions
    }
    /// Consumes the builder and constructs a [`GetPropertyValueInput`](crate::operation::get_property_value::GetPropertyValueInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::get_property_value::GetPropertyValueInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::get_property_value::GetPropertyValueInput {
            component_name: self.component_name,
            component_path: self.component_path,
            component_type_id: self.component_type_id,
            entity_id: self.entity_id,
            selected_properties: self.selected_properties,
            workspace_id: self.workspace_id,
            max_results: self.max_results,
            next_token: self.next_token,
            property_group_name: self.property_group_name,
            tabular_conditions: self.tabular_conditions,
        })
    }
}