Struct aws_sdk_iot::model::attribute_payload::Builder
source · pub struct Builder { /* private fields */ }
Expand description
A builder for AttributePayload
.
Implementations§
source§impl Builder
impl Builder
sourcepub fn attributes(self, k: impl Into<String>, v: impl Into<String>) -> Self
pub fn attributes(self, k: impl Into<String>, v: impl Into<String>) -> Self
Adds a key-value pair to attributes
.
To override the contents of this collection use set_attributes
.
A JSON string containing up to three key-value pair in JSON format. For example:
{\"attributes\":{\"string1\":\"string2\"}}
sourcepub fn set_attributes(self, input: Option<HashMap<String, String>>) -> Self
pub fn set_attributes(self, input: Option<HashMap<String, String>>) -> Self
A JSON string containing up to three key-value pair in JSON format. For example:
{\"attributes\":{\"string1\":\"string2\"}}
sourcepub fn merge(self, input: bool) -> Self
pub fn merge(self, input: bool) -> Self
Specifies whether the list of attributes provided in the AttributePayload
is merged with the attributes stored in the registry, instead of overwriting them.
To remove an attribute, call UpdateThing
with an empty attribute value.
The merge
attribute is only valid when calling UpdateThing
or UpdateThingGroup
.
sourcepub fn set_merge(self, input: Option<bool>) -> Self
pub fn set_merge(self, input: Option<bool>) -> Self
Specifies whether the list of attributes provided in the AttributePayload
is merged with the attributes stored in the registry, instead of overwriting them.
To remove an attribute, call UpdateThing
with an empty attribute value.
The merge
attribute is only valid when calling UpdateThing
or UpdateThingGroup
.
sourcepub fn build(self) -> AttributePayload
pub fn build(self) -> AttributePayload
Consumes the builder and constructs a AttributePayload
.