AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
PutInventoryRequest.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/core/utils/memory/stl/AWSVector.h>
9#include <aws/ssm/SSMRequest.h>
10#include <aws/ssm/SSM_EXPORTS.h>
11#include <aws/ssm/model/InventoryItem.h>
12
13#include <utility>
14
15namespace Aws {
16namespace SSM {
17namespace Model {
18
22 public:
23 AWS_SSM_API PutInventoryRequest() = default;
24
25 // Service request name is the Operation name which will send this request out,
26 // each operation should has unique request name, so that we can get operation's name from this request.
27 // Note: this is not true for response, multiple operations may have the same response name,
28 // so we can not get operation's name from response.
29 inline virtual const char* GetServiceRequestName() const override { return "PutInventory"; }
30
31 AWS_SSM_API Aws::String SerializePayload() const override;
32
34
36
39 inline const Aws::String& GetInstanceId() const { return m_instanceId; }
40 inline bool InstanceIdHasBeenSet() const { return m_instanceIdHasBeenSet; }
41 template <typename InstanceIdT = Aws::String>
42 void SetInstanceId(InstanceIdT&& value) {
43 m_instanceIdHasBeenSet = true;
44 m_instanceId = std::forward<InstanceIdT>(value);
45 }
46 template <typename InstanceIdT = Aws::String>
47 PutInventoryRequest& WithInstanceId(InstanceIdT&& value) {
48 SetInstanceId(std::forward<InstanceIdT>(value));
49 return *this;
50 }
52
54
57 inline const Aws::Vector<InventoryItem>& GetItems() const { return m_items; }
58 inline bool ItemsHasBeenSet() const { return m_itemsHasBeenSet; }
59 template <typename ItemsT = Aws::Vector<InventoryItem>>
60 void SetItems(ItemsT&& value) {
61 m_itemsHasBeenSet = true;
62 m_items = std::forward<ItemsT>(value);
63 }
64 template <typename ItemsT = Aws::Vector<InventoryItem>>
65 PutInventoryRequest& WithItems(ItemsT&& value) {
66 SetItems(std::forward<ItemsT>(value));
67 return *this;
68 }
69 template <typename ItemsT = InventoryItem>
70 PutInventoryRequest& AddItems(ItemsT&& value) {
71 m_itemsHasBeenSet = true;
72 m_items.emplace_back(std::forward<ItemsT>(value));
73 return *this;
74 }
76 private:
77 Aws::String m_instanceId;
78
80 bool m_instanceIdHasBeenSet = false;
81 bool m_itemsHasBeenSet = false;
82};
83
84} // namespace Model
85} // namespace SSM
86} // namespace Aws
const Aws::Vector< InventoryItem > & GetItems() const
PutInventoryRequest & AddItems(ItemsT &&value)
virtual const char * GetServiceRequestName() const override
PutInventoryRequest & WithItems(ItemsT &&value)
const Aws::String & GetInstanceId() const
AWS_SSM_API Aws::String SerializePayload() const override
void SetInstanceId(InstanceIdT &&value)
AWS_SSM_API PutInventoryRequest()=default
PutInventoryRequest & WithInstanceId(InstanceIdT &&value)
AWS_SSM_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector