AWS SDK for C++  0.14.3
AWS SDK for C++
LoadBalancerState.h
Go to the documentation of this file.
1 /*
2 * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License").
5 * You may not use this file except in compliance with the License.
6 * A copy of the License is located at
7 *
8 * http://aws.amazon.com/apache2.0
9 *
10 * or in the "license" file accompanying this file. This file is distributed
11 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12 * express or implied. See the License for the specific language governing
13 * permissions and limitations under the License.
14 */
15 #pragma once
20 
21 namespace Aws
22 {
23 namespace Utils
24 {
25 namespace Xml
26 {
27  class XmlNode;
28 } // namespace Xml
29 } // namespace Utils
30 namespace ElasticLoadBalancingv2
31 {
32 namespace Model
33 {
34 
39  {
40  public:
43  LoadBalancerState& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
44 
45  void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
46  void OutputToStream(Aws::OStream& oStream, const char* location) const;
47 
54  inline const LoadBalancerStateEnum& GetCode() const{ return m_code; }
55 
62  inline void SetCode(const LoadBalancerStateEnum& value) { m_codeHasBeenSet = true; m_code = value; }
63 
70  inline void SetCode(LoadBalancerStateEnum&& value) { m_codeHasBeenSet = true; m_code = value; }
71 
78  inline LoadBalancerState& WithCode(const LoadBalancerStateEnum& value) { SetCode(value); return *this;}
79 
86  inline LoadBalancerState& WithCode(LoadBalancerStateEnum&& value) { SetCode(value); return *this;}
87 
91  inline const Aws::String& GetReason() const{ return m_reason; }
92 
96  inline void SetReason(const Aws::String& value) { m_reasonHasBeenSet = true; m_reason = value; }
97 
101  inline void SetReason(Aws::String&& value) { m_reasonHasBeenSet = true; m_reason = value; }
102 
106  inline void SetReason(const char* value) { m_reasonHasBeenSet = true; m_reason.assign(value); }
107 
111  inline LoadBalancerState& WithReason(const Aws::String& value) { SetReason(value); return *this;}
112 
116  inline LoadBalancerState& WithReason(Aws::String&& value) { SetReason(value); return *this;}
117 
121  inline LoadBalancerState& WithReason(const char* value) { SetReason(value); return *this;}
122 
123  private:
124  LoadBalancerStateEnum m_code;
125  bool m_codeHasBeenSet;
126  Aws::String m_reason;
127  bool m_reasonHasBeenSet;
128  };
129 
130 } // namespace Model
131 } // namespace ElasticLoadBalancingv2
132 } // namespace Aws
void SetCode(const LoadBalancerStateEnum &value)
LoadBalancerState & WithCode(LoadBalancerStateEnum &&value)
const LoadBalancerStateEnum & GetCode() const
LoadBalancerState & WithReason(const char *value)
std::basic_ostream< char, std::char_traits< char > > OStream
Definition: AWSStreamFwd.h:31
LoadBalancerState & WithReason(Aws::String &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
LoadBalancerState & WithCode(const LoadBalancerStateEnum &value)
#define AWS_ELASTICLOADBALANCINGV2_API
LoadBalancerState & WithReason(const Aws::String &value)
JSON (JavaScript Object Notation).