AWS SDK for C++

AWS SDK for C++ Version 1.11.685

Loading...
Searching...
No Matches
AttachPolicyRequest.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/iot/IoTRequest.h>
9#include <aws/iot/IoT_EXPORTS.h>
10
11#include <utility>
12
13namespace Aws {
14namespace IoT {
15namespace Model {
16
20 public:
21 AWS_IOT_API AttachPolicyRequest() = default;
22
23 // Service request name is the Operation name which will send this request out,
24 // each operation should has unique request name, so that we can get operation's name from this request.
25 // Note: this is not true for response, multiple operations may have the same response name,
26 // so we can not get operation's name from response.
27 inline virtual const char* GetServiceRequestName() const override { return "AttachPolicy"; }
28
29 AWS_IOT_API Aws::String SerializePayload() const override;
30
32
35 inline const Aws::String& GetPolicyName() const { return m_policyName; }
36 inline bool PolicyNameHasBeenSet() const { return m_policyNameHasBeenSet; }
37 template <typename PolicyNameT = Aws::String>
38 void SetPolicyName(PolicyNameT&& value) {
39 m_policyNameHasBeenSet = true;
40 m_policyName = std::forward<PolicyNameT>(value);
41 }
42 template <typename PolicyNameT = Aws::String>
43 AttachPolicyRequest& WithPolicyName(PolicyNameT&& value) {
44 SetPolicyName(std::forward<PolicyNameT>(value));
45 return *this;
46 }
48
50
56 inline const Aws::String& GetTarget() const { return m_target; }
57 inline bool TargetHasBeenSet() const { return m_targetHasBeenSet; }
58 template <typename TargetT = Aws::String>
59 void SetTarget(TargetT&& value) {
60 m_targetHasBeenSet = true;
61 m_target = std::forward<TargetT>(value);
62 }
63 template <typename TargetT = Aws::String>
64 AttachPolicyRequest& WithTarget(TargetT&& value) {
65 SetTarget(std::forward<TargetT>(value));
66 return *this;
67 }
69 private:
70 Aws::String m_policyName;
71 bool m_policyNameHasBeenSet = false;
72
73 Aws::String m_target;
74 bool m_targetHasBeenSet = false;
75};
76
77} // namespace Model
78} // namespace IoT
79} // namespace Aws
const Aws::String & GetPolicyName() const
AWS_IOT_API AttachPolicyRequest()=default
void SetPolicyName(PolicyNameT &&value)
AWS_IOT_API Aws::String SerializePayload() const override
AttachPolicyRequest & WithTarget(TargetT &&value)
const Aws::String & GetTarget() const
virtual const char * GetServiceRequestName() const override
AttachPolicyRequest & WithPolicyName(PolicyNameT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String