1 /** 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * SPDX-License-Identifier: Apache-2.0. 4 */ 5 6 #pragma once 7 #include <aws/elasticmapreduce/EMR_EXPORTS.h> 8 #include <aws/elasticmapreduce/EMRRequest.h> 9 #include <aws/core/utils/memory/stl/AWSString.h> 10 #include <aws/elasticmapreduce/model/ManagedScalingPolicy.h> 11 #include <utility> 12 13 namespace Aws 14 { 15 namespace EMR 16 { 17 namespace Model 18 { 19 20 /** 21 */ 22 class AWS_EMR_API PutManagedScalingPolicyRequest : public EMRRequest 23 { 24 public: 25 PutManagedScalingPolicyRequest(); 26 27 // Service request name is the Operation name which will send this request out, 28 // each operation should has unique request name, so that we can get operation's name from this request. 29 // Note: this is not true for response, multiple operations may have the same response name, 30 // so we can not get operation's name from response. GetServiceRequestName()31 inline virtual const char* GetServiceRequestName() const override { return "PutManagedScalingPolicy"; } 32 33 Aws::String SerializePayload() const override; 34 35 Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; 36 37 38 /** 39 * <p>Specifies the ID of an EMR cluster where the managed scaling policy is 40 * attached. </p> 41 */ GetClusterId()42 inline const Aws::String& GetClusterId() const{ return m_clusterId; } 43 44 /** 45 * <p>Specifies the ID of an EMR cluster where the managed scaling policy is 46 * attached. </p> 47 */ ClusterIdHasBeenSet()48 inline bool ClusterIdHasBeenSet() const { return m_clusterIdHasBeenSet; } 49 50 /** 51 * <p>Specifies the ID of an EMR cluster where the managed scaling policy is 52 * attached. </p> 53 */ SetClusterId(const Aws::String & value)54 inline void SetClusterId(const Aws::String& value) { m_clusterIdHasBeenSet = true; m_clusterId = value; } 55 56 /** 57 * <p>Specifies the ID of an EMR cluster where the managed scaling policy is 58 * attached. </p> 59 */ SetClusterId(Aws::String && value)60 inline void SetClusterId(Aws::String&& value) { m_clusterIdHasBeenSet = true; m_clusterId = std::move(value); } 61 62 /** 63 * <p>Specifies the ID of an EMR cluster where the managed scaling policy is 64 * attached. </p> 65 */ SetClusterId(const char * value)66 inline void SetClusterId(const char* value) { m_clusterIdHasBeenSet = true; m_clusterId.assign(value); } 67 68 /** 69 * <p>Specifies the ID of an EMR cluster where the managed scaling policy is 70 * attached. </p> 71 */ WithClusterId(const Aws::String & value)72 inline PutManagedScalingPolicyRequest& WithClusterId(const Aws::String& value) { SetClusterId(value); return *this;} 73 74 /** 75 * <p>Specifies the ID of an EMR cluster where the managed scaling policy is 76 * attached. </p> 77 */ WithClusterId(Aws::String && value)78 inline PutManagedScalingPolicyRequest& WithClusterId(Aws::String&& value) { SetClusterId(std::move(value)); return *this;} 79 80 /** 81 * <p>Specifies the ID of an EMR cluster where the managed scaling policy is 82 * attached. </p> 83 */ WithClusterId(const char * value)84 inline PutManagedScalingPolicyRequest& WithClusterId(const char* value) { SetClusterId(value); return *this;} 85 86 87 /** 88 * <p>Specifies the constraints for the managed scaling policy. </p> 89 */ GetManagedScalingPolicy()90 inline const ManagedScalingPolicy& GetManagedScalingPolicy() const{ return m_managedScalingPolicy; } 91 92 /** 93 * <p>Specifies the constraints for the managed scaling policy. </p> 94 */ ManagedScalingPolicyHasBeenSet()95 inline bool ManagedScalingPolicyHasBeenSet() const { return m_managedScalingPolicyHasBeenSet; } 96 97 /** 98 * <p>Specifies the constraints for the managed scaling policy. </p> 99 */ SetManagedScalingPolicy(const ManagedScalingPolicy & value)100 inline void SetManagedScalingPolicy(const ManagedScalingPolicy& value) { m_managedScalingPolicyHasBeenSet = true; m_managedScalingPolicy = value; } 101 102 /** 103 * <p>Specifies the constraints for the managed scaling policy. </p> 104 */ SetManagedScalingPolicy(ManagedScalingPolicy && value)105 inline void SetManagedScalingPolicy(ManagedScalingPolicy&& value) { m_managedScalingPolicyHasBeenSet = true; m_managedScalingPolicy = std::move(value); } 106 107 /** 108 * <p>Specifies the constraints for the managed scaling policy. </p> 109 */ WithManagedScalingPolicy(const ManagedScalingPolicy & value)110 inline PutManagedScalingPolicyRequest& WithManagedScalingPolicy(const ManagedScalingPolicy& value) { SetManagedScalingPolicy(value); return *this;} 111 112 /** 113 * <p>Specifies the constraints for the managed scaling policy. </p> 114 */ WithManagedScalingPolicy(ManagedScalingPolicy && value)115 inline PutManagedScalingPolicyRequest& WithManagedScalingPolicy(ManagedScalingPolicy&& value) { SetManagedScalingPolicy(std::move(value)); return *this;} 116 117 private: 118 119 Aws::String m_clusterId; 120 bool m_clusterIdHasBeenSet; 121 122 ManagedScalingPolicy m_managedScalingPolicy; 123 bool m_managedScalingPolicyHasBeenSet; 124 }; 125 126 } // namespace Model 127 } // namespace EMR 128 } // namespace Aws 129