Skip to content

Commit

Permalink
code gen for #3277
Browse files Browse the repository at this point in the history
  • Loading branch information
SergeyRyabinin committed Jan 31, 2025
1 parent 31bd8bc commit 7f9d72c
Show file tree
Hide file tree
Showing 25 changed files with 140 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ namespace EC2Protocol
{
namespace Model
{
class RecursiveXmlShapesOutputNested2;

class RecursiveXmlShapesOutputNested1
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ namespace EC2Protocol
{
namespace Model
{
class RecursiveXmlShapesOutputNested1;

class RecursiveXmlShapesOutputNested2
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,12 @@ XmlTimestampsResponse& XmlTimestampsResponse::operator =(const Aws::AmazonWebSer
XmlNode epochSecondsNode = resultNode.FirstChild("epochSeconds");
if(!epochSecondsNode.IsNull())
{
m_epochSeconds = DateTime(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsNode.GetText()).c_str()).c_str(), Aws::Utils::DateFormat::$CppViewHelper.computeTimestampFormatInXml($member.shape));
m_epochSeconds = DateTime(StringUtils::ConvertToDouble(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsNode.GetText()).c_str()).c_str()));
}
XmlNode epochSecondsOnTargetNode = resultNode.FirstChild("epochSecondsOnTarget");
if(!epochSecondsOnTargetNode.IsNull())
{
m_epochSecondsOnTarget = DateTime(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsOnTargetNode.GetText()).c_str()).c_str(), Aws::Utils::DateFormat::$CppViewHelper.computeTimestampFormatInXml($member.shape));
m_epochSecondsOnTarget = DateTime(StringUtils::ConvertToDouble(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsOnTargetNode.GetText()).c_str()).c_str()));
}
XmlNode httpDateNode = resultNode.FirstChild("httpDate");
if(!httpDateNode.IsNull())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ namespace QueryProtocol
{
namespace Model
{
class RecursiveXmlShapesOutputNested2;

class RecursiveXmlShapesOutputNested1
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ namespace QueryProtocol
{
namespace Model
{
class RecursiveXmlShapesOutputNested1;

class RecursiveXmlShapesOutputNested2
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,12 @@ XmlTimestampsResult& XmlTimestampsResult::operator =(const Aws::AmazonWebService
XmlNode epochSecondsNode = resultNode.FirstChild("epochSeconds");
if(!epochSecondsNode.IsNull())
{
m_epochSeconds = DateTime(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsNode.GetText()).c_str()).c_str(), Aws::Utils::DateFormat::$CppViewHelper.computeTimestampFormatInXml($member.shape));
m_epochSeconds = DateTime(StringUtils::ConvertToDouble(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsNode.GetText()).c_str()).c_str()));
}
XmlNode epochSecondsOnTargetNode = resultNode.FirstChild("epochSecondsOnTarget");
if(!epochSecondsOnTargetNode.IsNull())
{
m_epochSecondsOnTarget = DateTime(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsOnTargetNode.GetText()).c_str()).c_str(), Aws::Utils::DateFormat::$CppViewHelper.computeTimestampFormatInXml($member.shape));
m_epochSecondsOnTarget = DateTime(StringUtils::ConvertToDouble(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsOnTargetNode.GetText()).c_str()).c_str()));
}
XmlNode httpDateNode = resultNode.FirstChild("httpDate");
if(!httpDateNode.IsNull())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ namespace RestXmlProtocol
{
namespace Model
{
class RecursiveShapesInputOutputNested2;

class RecursiveShapesInputOutputNested1
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ namespace RestXmlProtocol
{
namespace Model
{
class RecursiveShapesInputOutputNested1;

class RecursiveShapesInputOutputNested2
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,15 @@ Aws::String FlattenedXmlMapRequest::SerializePayload() const
Aws::StringStream ss;
if(m_myMapHasBeenSet)
{
XmlNode myMapParentNode = parentNode.CreateChildElement("myMap");
for(const auto& mapItem : m_myMap)
{
XmlNode myMapMapEntryNode = myMapParentNode.CreateChildElement("entry");
XmlNode myMapKeyNode = myMapMapEntryNode.CreateChildElement("key");
myMapKeyNode.SetText(mapItem.first);
XmlNode myMapValueNode = myMapMapEntryNode.CreateChildElement("value");
myMapValueNode.SetText(FooEnumMapper::GetNameForFooEnum(mapItem.second));
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,15 @@ Aws::String FlattenedXmlMapWithXmlNameRequest::SerializePayload() const
Aws::StringStream ss;
if(m_myMapHasBeenSet)
{
XmlNode myMapParentNode = parentNode.CreateChildElement("KVP");
for(const auto& mapItem : m_myMap)
{
XmlNode myMapMapEntryNode = myMapParentNode.CreateChildElement("KVP");
XmlNode myMapKeyNode = myMapMapEntryNode.CreateChildElement("K");
myMapKeyNode.SetText(mapItem.first);
XmlNode myMapValueNode = myMapMapEntryNode.CreateChildElement("V");
myMapValueNode.SetText(mapItem.second);
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,15 @@ Aws::String NestedXmlMapWithXmlNameRequest::SerializePayload() const
Aws::StringStream ss;
if(m_nestedXmlMapWithXmlNameMapHasBeenSet)
{
XmlNode nestedXmlMapWithXmlNameMapParentNode = parentNode.CreateChildElement("nestedXmlMapWithXmlNameMap");
for(const auto& mapItem : m_nestedXmlMapWithXmlNameMap)
{
XmlNode nestedXmlMapWithXmlNameMapMapEntryNode = nestedXmlMapWithXmlNameMapParentNode.CreateChildElement("entry");
XmlNode nestedXmlMapWithXmlNameMapKeyNode = nestedXmlMapWithXmlNameMapMapEntryNode.CreateChildElement("OuterKey");
nestedXmlMapWithXmlNameMapKeyNode.SetText(mapItem.first);
XmlNode nestedXmlMapWithXmlNameMapValueNode = nestedXmlMapWithXmlNameMapMapEntryNode.CreateChildElement("value");
nestedXmlMapWithXmlNameMapValueNode.SetText(mapItem.second);
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,28 @@ Aws::String NestedXmlMapsRequest::SerializePayload() const
Aws::StringStream ss;
if(m_nestedMapHasBeenSet)
{
XmlNode nestedMapParentNode = parentNode.CreateChildElement("nestedMap");
for(const auto& mapItem : m_nestedMap)
{
XmlNode nestedMapMapEntryNode = nestedMapParentNode.CreateChildElement("entry");
XmlNode nestedMapKeyNode = nestedMapMapEntryNode.CreateChildElement("key");
nestedMapKeyNode.SetText(mapItem.first);
XmlNode nestedMapValueNode = nestedMapMapEntryNode.CreateChildElement("value");
nestedMapValueNode.SetText(mapItem.second);
}
}

if(m_flatNestedMapHasBeenSet)
{
XmlNode flatNestedMapParentNode = parentNode.CreateChildElement("flatNestedMap");
for(const auto& mapItem : m_flatNestedMap)
{
XmlNode flatNestedMapMapEntryNode = flatNestedMapParentNode.CreateChildElement("entry");
XmlNode flatNestedMapKeyNode = flatNestedMapMapEntryNode.CreateChildElement("key");
flatNestedMapKeyNode.SetText(mapItem.first);
XmlNode flatNestedMapValueNode = flatNestedMapMapEntryNode.CreateChildElement("value");
flatNestedMapValueNode.SetText(mapItem.second);
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ Aws::String XmlEmptyListsRequest::SerializePayload() const
for(const auto& item : m_timestampList)
{
XmlNode timestampListNode = timestampListParentNode.CreateChildElement("Timestamp");
timestampListNode.SetText(item.ToGmtString(Aws::Utils::DateFormat::ISO_8601);
timestampListNode.SetText(item.ToGmtString(Aws::Utils::DateFormat::ISO_8601));
}
}

Expand Down Expand Up @@ -122,6 +122,7 @@ Aws::String XmlEmptyListsRequest::SerializePayload() const
for(const auto& item : m_nestedStringList)
{
XmlNode nestedStringListNode = nestedStringListParentNode.CreateChildElement("StringList");
nestedStringListNode.SetText(item);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,15 @@ Aws::String XmlEmptyMapsRequest::SerializePayload() const
Aws::StringStream ss;
if(m_myMapHasBeenSet)
{
XmlNode myMapParentNode = parentNode.CreateChildElement("myMap");
for(const auto& mapItem : m_myMap)
{
XmlNode myMapMapEntryNode = myMapParentNode.CreateChildElement("entry");
XmlNode myMapKeyNode = myMapMapEntryNode.CreateChildElement("key");
myMapKeyNode.SetText(mapItem.first);
XmlNode myMapValueNode = myMapMapEntryNode.CreateChildElement("value");
mapItem.second.AddToNode(myMapValueNode);
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,15 @@ Aws::String XmlEnumsRequest::SerializePayload() const

if(m_fooEnumMapHasBeenSet)
{
XmlNode fooEnumMapParentNode = parentNode.CreateChildElement("fooEnumMap");
for(const auto& mapItem : m_fooEnumMap)
{
XmlNode fooEnumMapMapEntryNode = fooEnumMapParentNode.CreateChildElement("entry");
XmlNode fooEnumMapKeyNode = fooEnumMapMapEntryNode.CreateChildElement("key");
fooEnumMapKeyNode.SetText(mapItem.first);
XmlNode fooEnumMapValueNode = fooEnumMapMapEntryNode.CreateChildElement("value");
fooEnumMapValueNode.SetText(FooEnumMapper::GetNameForFooEnum(mapItem.second));
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,17 @@ Aws::String XmlIntEnumsRequest::SerializePayload() const

if(m_intEnumMapHasBeenSet)
{
XmlNode intEnumMapParentNode = parentNode.CreateChildElement("intEnumMap");
for(const auto& mapItem : m_intEnumMap)
{
XmlNode intEnumMapMapEntryNode = intEnumMapParentNode.CreateChildElement("entry");
XmlNode intEnumMapKeyNode = intEnumMapMapEntryNode.CreateChildElement("key");
intEnumMapKeyNode.SetText(mapItem.first);
XmlNode intEnumMapValueNode = intEnumMapMapEntryNode.CreateChildElement("value");
ss << mapItem.second;
intEnumMapValueNode.SetText(ss.str());
ss.str("");
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ Aws::String XmlListsRequest::SerializePayload() const
for(const auto& item : m_timestampList)
{
XmlNode timestampListNode = timestampListParentNode.CreateChildElement("Timestamp");
timestampListNode.SetText(item.ToGmtString(Aws::Utils::DateFormat::ISO_8601);
timestampListNode.SetText(item.ToGmtString(Aws::Utils::DateFormat::ISO_8601));
}
}

Expand Down Expand Up @@ -122,6 +122,7 @@ Aws::String XmlListsRequest::SerializePayload() const
for(const auto& item : m_nestedStringList)
{
XmlNode nestedStringListNode = nestedStringListParentNode.CreateChildElement("StringList");
nestedStringListNode.SetText(item);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,15 @@ Aws::String XmlMapWithXmlNamespaceRequest::SerializePayload() const
Aws::StringStream ss;
if(m_myMapHasBeenSet)
{
XmlNode myMapParentNode = parentNode.CreateChildElement("KVP");
for(const auto& mapItem : m_myMap)
{
XmlNode myMapMapEntryNode = myMapParentNode.CreateChildElement("KVP");
XmlNode myMapKeyNode = myMapMapEntryNode.CreateChildElement("K");
myMapKeyNode.SetText(mapItem.first);
XmlNode myMapValueNode = myMapMapEntryNode.CreateChildElement("V");
myMapValueNode.SetText(mapItem.second);
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,15 @@ Aws::String XmlMapsRequest::SerializePayload() const
Aws::StringStream ss;
if(m_myMapHasBeenSet)
{
XmlNode myMapParentNode = parentNode.CreateChildElement("myMap");
for(const auto& mapItem : m_myMap)
{
XmlNode myMapMapEntryNode = myMapParentNode.CreateChildElement("entry");
XmlNode myMapKeyNode = myMapMapEntryNode.CreateChildElement("key");
myMapKeyNode.SetText(mapItem.first);
XmlNode myMapValueNode = myMapMapEntryNode.CreateChildElement("value");
mapItem.second.AddToNode(myMapValueNode);
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,15 @@ Aws::String XmlMapsXmlNameRequest::SerializePayload() const
Aws::StringStream ss;
if(m_myMapHasBeenSet)
{
XmlNode myMapParentNode = parentNode.CreateChildElement("myMap");
for(const auto& mapItem : m_myMap)
{
XmlNode myMapMapEntryNode = myMapParentNode.CreateChildElement("entry");
XmlNode myMapKeyNode = myMapMapEntryNode.CreateChildElement("Attribute");
myMapKeyNode.SetText(mapItem.first);
XmlNode myMapValueNode = myMapMapEntryNode.CreateChildElement("Setting");
mapItem.second.AddToNode(myMapValueNode);
}
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,25 +53,25 @@ Aws::String XmlTimestampsRequest::SerializePayload() const
if(m_epochSecondsHasBeenSet)
{
XmlNode epochSecondsNode = parentNode.CreateChildElement("epochSeconds");
epochSecondsNode.SetText(m_epochSeconds.ToGmtString(Aws::Utils::DateFormat::ISO_8601));
epochSecondsNode.SetText(StringUtils::to_string(m_epochSeconds.Seconds()));
}

if(m_epochSecondsOnTargetHasBeenSet)
{
XmlNode epochSecondsOnTargetNode = parentNode.CreateChildElement("epochSecondsOnTarget");
epochSecondsOnTargetNode.SetText(m_epochSecondsOnTarget.ToGmtString(Aws::Utils::DateFormat::ISO_8601));
epochSecondsOnTargetNode.SetText(StringUtils::to_string(m_epochSecondsOnTarget.Seconds()));
}

if(m_httpDateHasBeenSet)
{
XmlNode httpDateNode = parentNode.CreateChildElement("httpDate");
httpDateNode.SetText(m_httpDate.ToGmtString(Aws::Utils::DateFormat::ISO_8601));
httpDateNode.SetText(m_httpDate.ToGmtString(Aws::Utils::DateFormat::RFC822));
}

if(m_httpDateOnTargetHasBeenSet)
{
XmlNode httpDateOnTargetNode = parentNode.CreateChildElement("httpDateOnTarget");
httpDateOnTargetNode.SetText(m_httpDateOnTarget.ToGmtString(Aws::Utils::DateFormat::ISO_8601));
httpDateOnTargetNode.SetText(m_httpDateOnTarget.ToGmtString(Aws::Utils::DateFormat::RFC822));
}

return payloadDoc.ConvertToString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,12 @@ XmlTimestampsResult& XmlTimestampsResult::operator =(const Aws::AmazonWebService
XmlNode epochSecondsNode = resultNode.FirstChild("epochSeconds");
if(!epochSecondsNode.IsNull())
{
m_epochSeconds = DateTime(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsNode.GetText()).c_str()).c_str(), Aws::Utils::DateFormat::$CppViewHelper.computeTimestampFormatInXml($member.shape));
m_epochSeconds = DateTime(StringUtils::ConvertToDouble(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsNode.GetText()).c_str()).c_str()));
}
XmlNode epochSecondsOnTargetNode = resultNode.FirstChild("epochSecondsOnTarget");
if(!epochSecondsOnTargetNode.IsNull())
{
m_epochSecondsOnTarget = DateTime(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsOnTargetNode.GetText()).c_str()).c_str(), Aws::Utils::DateFormat::$CppViewHelper.computeTimestampFormatInXml($member.shape));
m_epochSecondsOnTarget = DateTime(StringUtils::ConvertToDouble(StringUtils::Trim(Aws::Utils::Xml::DecodeEscapedXmlText(epochSecondsOnTargetNode.GetText()).c_str()).c_str()));
}
XmlNode httpDateNode = resultNode.FirstChild("httpDate");
if(!httpDateNode.IsNull())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ void ObjectIdentifier::AddToNode(XmlNode& parentNode) const
if(m_lastModifiedTimeHasBeenSet)
{
XmlNode lastModifiedTimeNode = parentNode.CreateChildElement("LastModifiedTime");
lastModifiedTimeNode.SetText(m_lastModifiedTime.ToGmtString(Aws::Utils::DateFormat::ISO_8601));
lastModifiedTimeNode.SetText(m_lastModifiedTime.ToGmtString(Aws::Utils::DateFormat::RFC822));
}

if(m_sizeHasBeenSet)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,15 @@ void LambdaInvokeOperation::AddToNode(XmlNode& parentNode) const

if(m_userArgumentsHasBeenSet)
{
XmlNode userArgumentsParentNode = parentNode.CreateChildElement("UserArguments");
for(const auto& mapItem : m_userArguments)
{
XmlNode userArgumentsMapEntryNode = userArgumentsParentNode.CreateChildElement("entry");
XmlNode userArgumentsKeyNode = userArgumentsMapEntryNode.CreateChildElement("key");
userArgumentsKeyNode.SetText(mapItem.first);
XmlNode userArgumentsValueNode = userArgumentsMapEntryNode.CreateChildElement("value");
userArgumentsValueNode.SetText(mapItem.second);
}
}

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,15 @@ void S3ObjectMetadata::AddToNode(XmlNode& parentNode) const

if(m_userMetadataHasBeenSet)
{
XmlNode userMetadataParentNode = parentNode.CreateChildElement("UserMetadata");
for(const auto& mapItem : m_userMetadata)
{
XmlNode userMetadataMapEntryNode = userMetadataParentNode.CreateChildElement("entry");
XmlNode userMetadataKeyNode = userMetadataMapEntryNode.CreateChildElement("key");
userMetadataKeyNode.SetText(mapItem.first);
XmlNode userMetadataValueNode = userMetadataMapEntryNode.CreateChildElement("value");
userMetadataValueNode.SetText(mapItem.second);
}
}

if(m_contentLengthHasBeenSet)
Expand Down

0 comments on commit 7f9d72c

Please sign in to comment.