/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include #include #include #include #include using namespace Aws::Utils::Xml; using namespace Aws::Utils; namespace Aws { namespace ElastiCache { namespace Model { ParameterNameValue::ParameterNameValue() : m_parameterNameHasBeenSet(false), m_parameterValueHasBeenSet(false) { } ParameterNameValue::ParameterNameValue(const XmlNode& xmlNode) : m_parameterNameHasBeenSet(false), m_parameterValueHasBeenSet(false) { *this = xmlNode; } ParameterNameValue& ParameterNameValue::operator =(const XmlNode& xmlNode) { XmlNode resultNode = xmlNode; if(!resultNode.IsNull()) { XmlNode parameterNameNode = resultNode.FirstChild("ParameterName"); if(!parameterNameNode.IsNull()) { m_parameterName = Aws::Utils::Xml::DecodeEscapedXmlText(parameterNameNode.GetText()); m_parameterNameHasBeenSet = true; } XmlNode parameterValueNode = resultNode.FirstChild("ParameterValue"); if(!parameterValueNode.IsNull()) { m_parameterValue = Aws::Utils::Xml::DecodeEscapedXmlText(parameterValueNode.GetText()); m_parameterValueHasBeenSet = true; } } return *this; } void ParameterNameValue::OutputToStream(Aws::OStream& oStream, const char* location, unsigned index, const char* locationValue) const { if(m_parameterNameHasBeenSet) { oStream << location << index << locationValue << ".ParameterName=" << StringUtils::URLEncode(m_parameterName.c_str()) << "&"; } if(m_parameterValueHasBeenSet) { oStream << location << index << locationValue << ".ParameterValue=" << StringUtils::URLEncode(m_parameterValue.c_str()) << "&"; } } void ParameterNameValue::OutputToStream(Aws::OStream& oStream, const char* location) const { if(m_parameterNameHasBeenSet) { oStream << location << ".ParameterName=" << StringUtils::URLEncode(m_parameterName.c_str()) << "&"; } if(m_parameterValueHasBeenSet) { oStream << location << ".ParameterValue=" << StringUtils::URLEncode(m_parameterValue.c_str()) << "&"; } } } // namespace Model } // namespace ElastiCache } // namespace Aws