/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { namespace IoT { namespace Model { /** */ class UpdateThingGroupsForThingRequest : public IoTRequest { public: AWS_IOT_API UpdateThingGroupsForThingRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "UpdateThingGroupsForThing"; } AWS_IOT_API Aws::String SerializePayload() const override; /** *

The thing whose group memberships will be updated.

*/ inline const Aws::String& GetThingName() const{ return m_thingName; } /** *

The thing whose group memberships will be updated.

*/ inline bool ThingNameHasBeenSet() const { return m_thingNameHasBeenSet; } /** *

The thing whose group memberships will be updated.

*/ inline void SetThingName(const Aws::String& value) { m_thingNameHasBeenSet = true; m_thingName = value; } /** *

The thing whose group memberships will be updated.

*/ inline void SetThingName(Aws::String&& value) { m_thingNameHasBeenSet = true; m_thingName = std::move(value); } /** *

The thing whose group memberships will be updated.

*/ inline void SetThingName(const char* value) { m_thingNameHasBeenSet = true; m_thingName.assign(value); } /** *

The thing whose group memberships will be updated.

*/ inline UpdateThingGroupsForThingRequest& WithThingName(const Aws::String& value) { SetThingName(value); return *this;} /** *

The thing whose group memberships will be updated.

*/ inline UpdateThingGroupsForThingRequest& WithThingName(Aws::String&& value) { SetThingName(std::move(value)); return *this;} /** *

The thing whose group memberships will be updated.

*/ inline UpdateThingGroupsForThingRequest& WithThingName(const char* value) { SetThingName(value); return *this;} /** *

The groups to which the thing will be added.

*/ inline const Aws::Vector& GetThingGroupsToAdd() const{ return m_thingGroupsToAdd; } /** *

The groups to which the thing will be added.

*/ inline bool ThingGroupsToAddHasBeenSet() const { return m_thingGroupsToAddHasBeenSet; } /** *

The groups to which the thing will be added.

*/ inline void SetThingGroupsToAdd(const Aws::Vector& value) { m_thingGroupsToAddHasBeenSet = true; m_thingGroupsToAdd = value; } /** *

The groups to which the thing will be added.

*/ inline void SetThingGroupsToAdd(Aws::Vector&& value) { m_thingGroupsToAddHasBeenSet = true; m_thingGroupsToAdd = std::move(value); } /** *

The groups to which the thing will be added.

*/ inline UpdateThingGroupsForThingRequest& WithThingGroupsToAdd(const Aws::Vector& value) { SetThingGroupsToAdd(value); return *this;} /** *

The groups to which the thing will be added.

*/ inline UpdateThingGroupsForThingRequest& WithThingGroupsToAdd(Aws::Vector&& value) { SetThingGroupsToAdd(std::move(value)); return *this;} /** *

The groups to which the thing will be added.

*/ inline UpdateThingGroupsForThingRequest& AddThingGroupsToAdd(const Aws::String& value) { m_thingGroupsToAddHasBeenSet = true; m_thingGroupsToAdd.push_back(value); return *this; } /** *

The groups to which the thing will be added.

*/ inline UpdateThingGroupsForThingRequest& AddThingGroupsToAdd(Aws::String&& value) { m_thingGroupsToAddHasBeenSet = true; m_thingGroupsToAdd.push_back(std::move(value)); return *this; } /** *

The groups to which the thing will be added.

*/ inline UpdateThingGroupsForThingRequest& AddThingGroupsToAdd(const char* value) { m_thingGroupsToAddHasBeenSet = true; m_thingGroupsToAdd.push_back(value); return *this; } /** *

The groups from which the thing will be removed.

*/ inline const Aws::Vector& GetThingGroupsToRemove() const{ return m_thingGroupsToRemove; } /** *

The groups from which the thing will be removed.

*/ inline bool ThingGroupsToRemoveHasBeenSet() const { return m_thingGroupsToRemoveHasBeenSet; } /** *

The groups from which the thing will be removed.

*/ inline void SetThingGroupsToRemove(const Aws::Vector& value) { m_thingGroupsToRemoveHasBeenSet = true; m_thingGroupsToRemove = value; } /** *

The groups from which the thing will be removed.

*/ inline void SetThingGroupsToRemove(Aws::Vector&& value) { m_thingGroupsToRemoveHasBeenSet = true; m_thingGroupsToRemove = std::move(value); } /** *

The groups from which the thing will be removed.

*/ inline UpdateThingGroupsForThingRequest& WithThingGroupsToRemove(const Aws::Vector& value) { SetThingGroupsToRemove(value); return *this;} /** *

The groups from which the thing will be removed.

*/ inline UpdateThingGroupsForThingRequest& WithThingGroupsToRemove(Aws::Vector&& value) { SetThingGroupsToRemove(std::move(value)); return *this;} /** *

The groups from which the thing will be removed.

*/ inline UpdateThingGroupsForThingRequest& AddThingGroupsToRemove(const Aws::String& value) { m_thingGroupsToRemoveHasBeenSet = true; m_thingGroupsToRemove.push_back(value); return *this; } /** *

The groups from which the thing will be removed.

*/ inline UpdateThingGroupsForThingRequest& AddThingGroupsToRemove(Aws::String&& value) { m_thingGroupsToRemoveHasBeenSet = true; m_thingGroupsToRemove.push_back(std::move(value)); return *this; } /** *

The groups from which the thing will be removed.

*/ inline UpdateThingGroupsForThingRequest& AddThingGroupsToRemove(const char* value) { m_thingGroupsToRemoveHasBeenSet = true; m_thingGroupsToRemove.push_back(value); return *this; } /** *

Override dynamic thing groups with static thing groups when 10-group limit is * reached. If a thing belongs to 10 thing groups, and one or more of those groups * are dynamic thing groups, adding a thing to a static group removes the thing * from the last dynamic group.

*/ inline bool GetOverrideDynamicGroups() const{ return m_overrideDynamicGroups; } /** *

Override dynamic thing groups with static thing groups when 10-group limit is * reached. If a thing belongs to 10 thing groups, and one or more of those groups * are dynamic thing groups, adding a thing to a static group removes the thing * from the last dynamic group.

*/ inline bool OverrideDynamicGroupsHasBeenSet() const { return m_overrideDynamicGroupsHasBeenSet; } /** *

Override dynamic thing groups with static thing groups when 10-group limit is * reached. If a thing belongs to 10 thing groups, and one or more of those groups * are dynamic thing groups, adding a thing to a static group removes the thing * from the last dynamic group.

*/ inline void SetOverrideDynamicGroups(bool value) { m_overrideDynamicGroupsHasBeenSet = true; m_overrideDynamicGroups = value; } /** *

Override dynamic thing groups with static thing groups when 10-group limit is * reached. If a thing belongs to 10 thing groups, and one or more of those groups * are dynamic thing groups, adding a thing to a static group removes the thing * from the last dynamic group.

*/ inline UpdateThingGroupsForThingRequest& WithOverrideDynamicGroups(bool value) { SetOverrideDynamicGroups(value); return *this;} private: Aws::String m_thingName; bool m_thingNameHasBeenSet = false; Aws::Vector m_thingGroupsToAdd; bool m_thingGroupsToAddHasBeenSet = false; Aws::Vector m_thingGroupsToRemove; bool m_thingGroupsToRemoveHasBeenSet = false; bool m_overrideDynamicGroups; bool m_overrideDynamicGroupsHasBeenSet = false; }; } // namespace Model } // namespace IoT } // namespace Aws