本文整理汇总了C++中XmlNode类的典型用法代码示例。如果您正苦于以下问题:C++ XmlNode类的具体用法?C++ XmlNode怎么用?C++ XmlNode使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了XmlNode类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1:
GetShippingLabelResult& GetShippingLabelResult::operator =(const AmazonWebServiceResult<XmlDocument>& result)
{
const XmlDocument& xmlDocument = result.GetPayload();
XmlNode rootNode = xmlDocument.GetRootElement();
XmlNode resultNode = rootNode;
if (rootNode.GetName() != "GetShippingLabelResult")
{
resultNode = rootNode.FirstChild("GetShippingLabelResult");
}
if(!resultNode.IsNull())
{
XmlNode shippingLabelURLNode = resultNode.FirstChild("ShippingLabelURL");
if(!shippingLabelURLNode.IsNull())
{
m_shippingLabelURL = StringUtils::Trim(shippingLabelURLNode.GetText().c_str());
}
XmlNode warningNode = resultNode.FirstChild("Warning");
if(!warningNode.IsNull())
{
m_warning = StringUtils::Trim(warningNode.GetText().c_str());
}
}
XmlNode responseMetadataNode = rootNode.FirstChild("ResponseMetadata");
m_responseMetadata = responseMetadataNode;
AWS_LOGSTREAM_DEBUG("Aws::ImportExport::Model::GetShippingLabelResult", "x-amzn-request-id: " << m_responseMetadata.GetRequestId() );
return *this;
}
示例2: DateTime
SpotInstanceRequest& SpotInstanceRequest::operator =(const XmlNode& xmlNode)
{
XmlNode resultNode = xmlNode;
if(!resultNode.IsNull())
{
XmlNode actualBlockHourlyPriceNode = resultNode.FirstChild("actualBlockHourlyPrice");
if(!actualBlockHourlyPriceNode.IsNull())
{
m_actualBlockHourlyPrice = StringUtils::Trim(actualBlockHourlyPriceNode.GetText().c_str());
m_actualBlockHourlyPriceHasBeenSet = true;
}
XmlNode availabilityZoneGroupNode = resultNode.FirstChild("availabilityZoneGroup");
if(!availabilityZoneGroupNode.IsNull())
{
m_availabilityZoneGroup = StringUtils::Trim(availabilityZoneGroupNode.GetText().c_str());
m_availabilityZoneGroupHasBeenSet = true;
}
XmlNode blockDurationMinutesNode = resultNode.FirstChild("blockDurationMinutes");
if(!blockDurationMinutesNode.IsNull())
{
m_blockDurationMinutes = StringUtils::ConvertToInt32(StringUtils::Trim(blockDurationMinutesNode.GetText().c_str()).c_str());
m_blockDurationMinutesHasBeenSet = true;
}
XmlNode createTimeNode = resultNode.FirstChild("createTime");
if(!createTimeNode.IsNull())
{
m_createTime = DateTime(StringUtils::Trim(createTimeNode.GetText().c_str()).c_str(), DateFormat::ISO_8601);
m_createTimeHasBeenSet = true;
}
XmlNode faultNode = resultNode.FirstChild("fault");
if(!faultNode.IsNull())
{
m_fault = faultNode;
m_faultHasBeenSet = true;
}
XmlNode instanceIdNode = resultNode.FirstChild("instanceId");
if(!instanceIdNode.IsNull())
{
m_instanceId = StringUtils::Trim(instanceIdNode.GetText().c_str());
m_instanceIdHasBeenSet = true;
}
XmlNode launchGroupNode = resultNode.FirstChild("launchGroup");
if(!launchGroupNode.IsNull())
{
m_launchGroup = StringUtils::Trim(launchGroupNode.GetText().c_str());
m_launchGroupHasBeenSet = true;
}
XmlNode launchSpecificationNode = resultNode.FirstChild("launchSpecification");
if(!launchSpecificationNode.IsNull())
{
m_launchSpecification = launchSpecificationNode;
m_launchSpecificationHasBeenSet = true;
}
XmlNode launchedAvailabilityZoneNode = resultNode.FirstChild("launchedAvailabilityZone");
if(!launchedAvailabilityZoneNode.IsNull())
{
m_launchedAvailabilityZone = StringUtils::Trim(launchedAvailabilityZoneNode.GetText().c_str());
m_launchedAvailabilityZoneHasBeenSet = true;
}
XmlNode productDescriptionNode = resultNode.FirstChild("productDescription");
if(!productDescriptionNode.IsNull())
{
m_productDescription = RIProductDescriptionMapper::GetRIProductDescriptionForName(StringUtils::Trim(productDescriptionNode.GetText().c_str()).c_str());
m_productDescriptionHasBeenSet = true;
}
XmlNode spotInstanceRequestIdNode = resultNode.FirstChild("spotInstanceRequestId");
if(!spotInstanceRequestIdNode.IsNull())
{
m_spotInstanceRequestId = StringUtils::Trim(spotInstanceRequestIdNode.GetText().c_str());
m_spotInstanceRequestIdHasBeenSet = true;
}
XmlNode spotPriceNode = resultNode.FirstChild("spotPrice");
if(!spotPriceNode.IsNull())
{
m_spotPrice = StringUtils::Trim(spotPriceNode.GetText().c_str());
m_spotPriceHasBeenSet = true;
}
XmlNode stateNode = resultNode.FirstChild("state");
if(!stateNode.IsNull())
{
m_state = SpotInstanceStateMapper::GetSpotInstanceStateForName(StringUtils::Trim(stateNode.GetText().c_str()).c_str());
m_stateHasBeenSet = true;
}
XmlNode statusNode = resultNode.FirstChild("status");
if(!statusNode.IsNull())
{
m_status = statusNode;
m_statusHasBeenSet = true;
}
XmlNode tagsNode = resultNode.FirstChild("tagSet");
if(!tagsNode.IsNull())
{
XmlNode tagsMember = tagsNode.FirstChild("item");
while(!tagsMember.IsNull())
{
m_tags.push_back(tagsMember);
tagsMember = tagsMember.NextNode("item");
}
//.........这里部分代码省略.........
示例3: DateTime
GetStatusResult& GetStatusResult::operator =(const AmazonWebServiceResult<XmlDocument>& result)
{
const XmlDocument& xmlDocument = result.GetPayload();
XmlNode rootNode = xmlDocument.GetRootElement();
XmlNode resultNode = rootNode;
if (rootNode.GetName() != "GetStatusResult")
{
resultNode = rootNode.FirstChild("GetStatusResult");
}
if(!resultNode.IsNull())
{
XmlNode jobIdNode = resultNode.FirstChild("JobId");
if(!jobIdNode.IsNull())
{
m_jobId = StringUtils::Trim(jobIdNode.GetText().c_str());
}
XmlNode jobTypeNode = resultNode.FirstChild("JobType");
if(!jobTypeNode.IsNull())
{
m_jobType = JobTypeMapper::GetJobTypeForName(StringUtils::Trim(jobTypeNode.GetText().c_str()).c_str());
}
XmlNode locationCodeNode = resultNode.FirstChild("LocationCode");
if(!locationCodeNode.IsNull())
{
m_locationCode = StringUtils::Trim(locationCodeNode.GetText().c_str());
}
XmlNode locationMessageNode = resultNode.FirstChild("LocationMessage");
if(!locationMessageNode.IsNull())
{
m_locationMessage = StringUtils::Trim(locationMessageNode.GetText().c_str());
}
XmlNode progressCodeNode = resultNode.FirstChild("ProgressCode");
if(!progressCodeNode.IsNull())
{
m_progressCode = StringUtils::Trim(progressCodeNode.GetText().c_str());
}
XmlNode progressMessageNode = resultNode.FirstChild("ProgressMessage");
if(!progressMessageNode.IsNull())
{
m_progressMessage = StringUtils::Trim(progressMessageNode.GetText().c_str());
}
XmlNode carrierNode = resultNode.FirstChild("Carrier");
if(!carrierNode.IsNull())
{
m_carrier = StringUtils::Trim(carrierNode.GetText().c_str());
}
XmlNode trackingNumberNode = resultNode.FirstChild("TrackingNumber");
if(!trackingNumberNode.IsNull())
{
m_trackingNumber = StringUtils::Trim(trackingNumberNode.GetText().c_str());
}
XmlNode logBucketNode = resultNode.FirstChild("LogBucket");
if(!logBucketNode.IsNull())
{
m_logBucket = StringUtils::Trim(logBucketNode.GetText().c_str());
}
XmlNode logKeyNode = resultNode.FirstChild("LogKey");
if(!logKeyNode.IsNull())
{
m_logKey = StringUtils::Trim(logKeyNode.GetText().c_str());
}
XmlNode errorCountNode = resultNode.FirstChild("ErrorCount");
if(!errorCountNode.IsNull())
{
m_errorCount = StringUtils::ConvertToInt32(StringUtils::Trim(errorCountNode.GetText().c_str()).c_str());
}
XmlNode signatureNode = resultNode.FirstChild("Signature");
if(!signatureNode.IsNull())
{
m_signature = StringUtils::Trim(signatureNode.GetText().c_str());
}
XmlNode signatureFileContentsNode = resultNode.FirstChild("SignatureFileContents");
if(!signatureFileContentsNode.IsNull())
{
m_signatureFileContents = StringUtils::Trim(signatureFileContentsNode.GetText().c_str());
}
XmlNode currentManifestNode = resultNode.FirstChild("CurrentManifest");
if(!currentManifestNode.IsNull())
{
m_currentManifest = StringUtils::Trim(currentManifestNode.GetText().c_str());
}
XmlNode creationDateNode = resultNode.FirstChild("CreationDate");
if(!creationDateNode.IsNull())
{
m_creationDate = DateTime(StringUtils::Trim(creationDateNode.GetText().c_str()).c_str(), DateFormat::ISO_8601);
}
XmlNode artifactListNode = resultNode.FirstChild("ArtifactList");
if(!artifactListNode.IsNull())
{
XmlNode artifactListMember = artifactListNode.FirstChild("member");
while(!artifactListMember.IsNull())
{
m_artifactList.push_back(artifactListMember);
artifactListMember = artifactListMember.NextNode("member");
}
}
}
//.........这里部分代码省略.........
示例4: while
PolicyTypeDescription& PolicyTypeDescription::operator =(const XmlNode& xmlNode)
{
XmlNode resultNode = xmlNode;
if(!resultNode.IsNull())
{
XmlNode policyTypeNameNode = resultNode.FirstChild("PolicyTypeName");
if(!policyTypeNameNode.IsNull())
{
m_policyTypeName = StringUtils::Trim(policyTypeNameNode.GetText().c_str());
m_policyTypeNameHasBeenSet = true;
}
XmlNode descriptionNode = resultNode.FirstChild("Description");
if(!descriptionNode.IsNull())
{
m_description = StringUtils::Trim(descriptionNode.GetText().c_str());
m_descriptionHasBeenSet = true;
}
XmlNode policyAttributeTypeDescriptionsNode = resultNode.FirstChild("PolicyAttributeTypeDescriptions");
if(!policyAttributeTypeDescriptionsNode.IsNull())
{
XmlNode policyAttributeTypeDescriptionsMember = policyAttributeTypeDescriptionsNode.FirstChild("member");
while(!policyAttributeTypeDescriptionsMember.IsNull())
{
m_policyAttributeTypeDescriptions.push_back(policyAttributeTypeDescriptionsMember);
policyAttributeTypeDescriptionsMember = policyAttributeTypeDescriptionsMember.NextNode("member");
}
m_policyAttributeTypeDescriptionsHasBeenSet = true;
}
}
return *this;
}
示例5: while
UnmonitorInstancesResponse& UnmonitorInstancesResponse::operator =(const AmazonWebServiceResult<XmlDocument>& result)
{
const XmlDocument& xmlDocument = result.GetPayload();
XmlNode rootNode = xmlDocument.GetRootElement();
XmlNode resultNode = rootNode;
if (rootNode.GetName() != "UnmonitorInstancesResponse")
{
resultNode = rootNode.FirstChild("UnmonitorInstancesResponse");
}
if(!resultNode.IsNull())
{
XmlNode instanceMonitoringsNode = resultNode.FirstChild("InstanceMonitorings");
if(!instanceMonitoringsNode.IsNull())
{
XmlNode instanceMonitoringsMember = instanceMonitoringsNode.FirstChild("item");
while(!instanceMonitoringsMember.IsNull())
{
m_instanceMonitorings.push_back(instanceMonitoringsMember);
instanceMonitoringsMember = instanceMonitoringsMember.NextNode("item");
}
}
}
XmlNode responseMetadataNode = rootNode.FirstChild("ResponseMetadata");
m_responseMetadata = responseMetadataNode;
AWS_LOGSTREAM_DEBUG("Aws::EC2::Model::UnmonitorInstancesResponse", "x-amzn-request-id: " << m_responseMetadata.GetRequestId() );
return *this;
}
示例6: while
ListGroupsForUserResult& ListGroupsForUserResult::operator =(const AmazonWebServiceResult<XmlDocument>& result)
{
const XmlDocument& xmlDocument = result.GetPayload();
XmlNode rootNode = xmlDocument.GetRootElement();
XmlNode resultNode = rootNode.FirstChild("ListGroupsForUserResult");
if(!resultNode.IsNull())
{
XmlNode groupsNode = resultNode.FirstChild("Groups");
if(!groupsNode.IsNull())
{
XmlNode groupsMember = groupsNode.FirstChild("member");
while(!groupsMember.IsNull())
{
m_groups.push_back(groupsMember);
groupsMember = groupsMember.NextNode("member");
}
}
XmlNode isTruncatedNode = resultNode.FirstChild("IsTruncated");
if(isTruncatedNode.IsNull())
{
isTruncatedNode = resultNode;
}
if(!isTruncatedNode.IsNull())
{
m_isTruncated = StringUtils::ConvertToBool(StringUtils::Trim(isTruncatedNode.GetText().c_str()).c_str());
}
XmlNode markerNode = resultNode.FirstChild("Marker");
if(markerNode.IsNull())
{
markerNode = resultNode;
}
if(!markerNode.IsNull())
{
m_marker = StringUtils::Trim(markerNode.GetText().c_str());
}
}
XmlNode responseMetadataNode = rootNode.FirstChild("ResponseMetadata");
m_responseMetadata = responseMetadataNode;
return *this;
}
示例7:
ObjectVersion& ObjectVersion::operator =(const XmlNode& xmlNode)
{
XmlNode resultNode = xmlNode;
if(!resultNode.IsNull())
{
XmlNode eTagNode = resultNode.FirstChild("ETag");
if(eTagNode.IsNull())
{
eTagNode = resultNode;
}
if(!eTagNode.IsNull())
{
m_eTag = StringUtils::Trim(eTagNode.GetText().c_str());
m_eTagHasBeenSet = true;
}
XmlNode sizeNode = resultNode.FirstChild("Size");
if(sizeNode.IsNull())
{
sizeNode = resultNode;
}
if(!sizeNode.IsNull())
{
m_size = StringUtils::ConvertToInt32(StringUtils::Trim(sizeNode.GetText().c_str()).c_str());
m_sizeHasBeenSet = true;
}
XmlNode storageClassNode = resultNode.FirstChild("StorageClass");
if(storageClassNode.IsNull())
{
storageClassNode = resultNode;
}
if(!storageClassNode.IsNull())
{
m_storageClass = ObjectVersionStorageClassMapper::GetObjectVersionStorageClassForName(StringUtils::Trim(storageClassNode.GetText().c_str()).c_str());
m_storageClassHasBeenSet = true;
}
XmlNode keyNode = resultNode.FirstChild("Key");
if(keyNode.IsNull())
{
keyNode = resultNode;
}
if(!keyNode.IsNull())
{
m_key = StringUtils::Trim(keyNode.GetText().c_str());
m_keyHasBeenSet = true;
}
XmlNode versionIdNode = resultNode.FirstChild("VersionId");
if(versionIdNode.IsNull())
{
versionIdNode = resultNode;
}
if(!versionIdNode.IsNull())
{
m_versionId = StringUtils::Trim(versionIdNode.GetText().c_str());
m_versionIdHasBeenSet = true;
}
XmlNode isLatestNode = resultNode.FirstChild("IsLatest");
if(isLatestNode.IsNull())
{
isLatestNode = resultNode;
}
if(!isLatestNode.IsNull())
{
m_isLatest = StringUtils::ConvertToBool(StringUtils::Trim(isLatestNode.GetText().c_str()).c_str());
m_isLatestHasBeenSet = true;
}
XmlNode lastModifiedNode = resultNode.FirstChild("LastModified");
if(lastModifiedNode.IsNull())
{
lastModifiedNode = resultNode;
}
if(!lastModifiedNode.IsNull())
{
m_lastModified = StringUtils::ConvertToDouble(StringUtils::Trim(lastModifiedNode.GetText().c_str()).c_str());
m_lastModifiedHasBeenSet = true;
}
XmlNode ownerNode = resultNode.FirstChild("Owner");
if(ownerNode.IsNull())
{
ownerNode = resultNode;
}
if(!ownerNode.IsNull())
{
m_owner = ownerNode;
m_ownerHasBeenSet = true;
}
}
return *this;
}
示例8:
DescribeDBLogFilesDetails& DescribeDBLogFilesDetails::operator =(const XmlNode& xmlNode)
{
XmlNode resultNode = xmlNode;
if(!resultNode.IsNull())
{
XmlNode logFileNameNode = resultNode.FirstChild("LogFileName");
if(logFileNameNode.IsNull())
{
logFileNameNode = resultNode;
}
if(!logFileNameNode.IsNull())
{
m_logFileName = StringUtils::Trim(logFileNameNode.GetText().c_str());
m_logFileNameHasBeenSet = true;
}
XmlNode lastWrittenNode = resultNode.FirstChild("LastWritten");
if(lastWrittenNode.IsNull())
{
lastWrittenNode = resultNode;
}
if(!lastWrittenNode.IsNull())
{
m_lastWritten = StringUtils::ConvertToInt64(StringUtils::Trim(lastWrittenNode.GetText().c_str()).c_str());
m_lastWrittenHasBeenSet = true;
}
XmlNode sizeNode = resultNode.FirstChild("Size");
if(sizeNode.IsNull())
{
sizeNode = resultNode;
}
if(!sizeNode.IsNull())
{
m_size = StringUtils::ConvertToInt64(StringUtils::Trim(sizeNode.GetText().c_str()).c_str());
m_sizeHasBeenSet = true;
}
}
return *this;
}
示例9:
AssumeRoleResult& AssumeRoleResult::operator =(const AmazonWebServiceResult<XmlDocument>& result)
{
const XmlDocument& xmlDocument = result.GetPayload();
XmlNode rootNode = xmlDocument.GetRootElement();
XmlNode resultNode = rootNode;
if (rootNode.GetName() != "AssumeRoleResult")
{
resultNode = rootNode.FirstChild("AssumeRoleResult");
}
if(!resultNode.IsNull())
{
XmlNode credentialsNode = resultNode.FirstChild("Credentials");
if(!credentialsNode.IsNull())
{
m_credentials = credentialsNode;
}
XmlNode assumedRoleUserNode = resultNode.FirstChild("AssumedRoleUser");
if(!assumedRoleUserNode.IsNull())
{
m_assumedRoleUser = assumedRoleUserNode;
}
XmlNode packedPolicySizeNode = resultNode.FirstChild("PackedPolicySize");
if(!packedPolicySizeNode.IsNull())
{
m_packedPolicySize = StringUtils::ConvertToInt32(StringUtils::Trim(packedPolicySizeNode.GetText().c_str()).c_str());
}
}
XmlNode responseMetadataNode = rootNode.FirstChild("ResponseMetadata");
m_responseMetadata = responseMetadataNode;
AWS_LOGSTREAM_DEBUG("Aws::STS::Model::AssumeRoleResult", "x-amzn-request-id: " << m_responseMetadata.GetRequestId() );
return *this;
}
示例10: while
ImportInstanceTaskDetails& ImportInstanceTaskDetails::operator =(const XmlNode& xmlNode)
{
XmlNode resultNode = xmlNode;
if(!resultNode.IsNull())
{
XmlNode descriptionNode = resultNode.FirstChild("description");
if(!descriptionNode.IsNull())
{
m_description = StringUtils::Trim(descriptionNode.GetText().c_str());
m_descriptionHasBeenSet = true;
}
XmlNode instanceIdNode = resultNode.FirstChild("instanceId");
if(!instanceIdNode.IsNull())
{
m_instanceId = StringUtils::Trim(instanceIdNode.GetText().c_str());
m_instanceIdHasBeenSet = true;
}
XmlNode platformNode = resultNode.FirstChild("platform");
if(!platformNode.IsNull())
{
m_platform = PlatformValuesMapper::GetPlatformValuesForName(StringUtils::Trim(platformNode.GetText().c_str()).c_str());
m_platformHasBeenSet = true;
}
XmlNode volumesNode = resultNode.FirstChild("volumes");
if(!volumesNode.IsNull())
{
XmlNode volumesMember = volumesNode.FirstChild("item");
while(!volumesMember.IsNull())
{
m_volumes.push_back(volumesMember);
volumesMember = volumesMember.NextNode("item");
}
m_volumesHasBeenSet = true;
}
}
return *this;
}
示例11: while
ActiveTrustedSigners& ActiveTrustedSigners::operator =(const XmlNode& xmlNode)
{
XmlNode resultNode = xmlNode;
if(!resultNode.IsNull())
{
XmlNode enabledNode = resultNode.FirstChild("Enabled");
if(!enabledNode.IsNull())
{
m_enabled = StringUtils::ConvertToBool(StringUtils::Trim(enabledNode.GetText().c_str()).c_str());
m_enabledHasBeenSet = true;
}
XmlNode quantityNode = resultNode.FirstChild("Quantity");
if(!quantityNode.IsNull())
{
m_quantity = StringUtils::ConvertToInt32(StringUtils::Trim(quantityNode.GetText().c_str()).c_str());
m_quantityHasBeenSet = true;
}
XmlNode itemsNode = resultNode.FirstChild("Items");
if(!itemsNode.IsNull())
{
XmlNode itemsMember = itemsNode.FirstChild("Signer");
while(!itemsMember.IsNull())
{
m_items.push_back(itemsMember);
itemsMember = itemsMember.NextNode("Signer");
}
m_itemsHasBeenSet = true;
}
}
return *this;
}
示例12: while
ListAttachedUserPoliciesResult& ListAttachedUserPoliciesResult::operator =(const AmazonWebServiceResult<XmlDocument>& result)
{
const XmlDocument& xmlDocument = result.GetPayload();
XmlNode rootNode = xmlDocument.GetRootElement();
XmlNode resultNode = rootNode;
if (rootNode.GetName() != "ListAttachedUserPoliciesResult")
{
resultNode = rootNode.FirstChild("ListAttachedUserPoliciesResult");
}
if(!resultNode.IsNull())
{
XmlNode attachedPoliciesNode = resultNode.FirstChild("AttachedPolicies");
if(!attachedPoliciesNode.IsNull())
{
XmlNode attachedPoliciesMember = attachedPoliciesNode.FirstChild("member");
while(!attachedPoliciesMember.IsNull())
{
m_attachedPolicies.push_back(attachedPoliciesMember);
attachedPoliciesMember = attachedPoliciesMember.NextNode("member");
}
}
XmlNode isTruncatedNode = resultNode.FirstChild("IsTruncated");
if(!isTruncatedNode.IsNull())
{
m_isTruncated = StringUtils::ConvertToBool(StringUtils::Trim(isTruncatedNode.GetText().c_str()).c_str());
}
XmlNode markerNode = resultNode.FirstChild("Marker");
if(!markerNode.IsNull())
{
m_marker = StringUtils::Trim(markerNode.GetText().c_str());
}
}
XmlNode responseMetadataNode = rootNode.FirstChild("ResponseMetadata");
m_responseMetadata = responseMetadataNode;
AWS_LOGSTREAM_DEBUG("Aws::IAM::Model::ListAttachedUserPoliciesResult", "x-amzn-request-id: " << m_responseMetadata.GetRequestId() );
return *this;
}
示例13: while
LaunchSpecification& LaunchSpecification::operator =(const XmlNode& xmlNode)
{
XmlNode resultNode = xmlNode;
if(!resultNode.IsNull())
{
XmlNode imageIdNode = resultNode.FirstChild("imageId");
if(!imageIdNode.IsNull())
{
m_imageId = StringUtils::Trim(imageIdNode.GetText().c_str());
m_imageIdHasBeenSet = true;
}
XmlNode keyNameNode = resultNode.FirstChild("keyName");
if(!keyNameNode.IsNull())
{
m_keyName = StringUtils::Trim(keyNameNode.GetText().c_str());
m_keyNameHasBeenSet = true;
}
XmlNode securityGroupsNode = resultNode.FirstChild("groupSet");
if(!securityGroupsNode.IsNull())
{
XmlNode securityGroupsMember = securityGroupsNode.FirstChild("item");
while(!securityGroupsMember.IsNull())
{
m_securityGroups.push_back(securityGroupsMember);
securityGroupsMember = securityGroupsMember.NextNode("item");
}
m_securityGroupsHasBeenSet = true;
}
XmlNode userDataNode = resultNode.FirstChild("userData");
if(!userDataNode.IsNull())
{
m_userData = StringUtils::Trim(userDataNode.GetText().c_str());
m_userDataHasBeenSet = true;
}
XmlNode addressingTypeNode = resultNode.FirstChild("addressingType");
if(!addressingTypeNode.IsNull())
{
m_addressingType = StringUtils::Trim(addressingTypeNode.GetText().c_str());
m_addressingTypeHasBeenSet = true;
}
XmlNode instanceTypeNode = resultNode.FirstChild("instanceType");
if(!instanceTypeNode.IsNull())
{
m_instanceType = InstanceTypeMapper::GetInstanceTypeForName(StringUtils::Trim(instanceTypeNode.GetText().c_str()).c_str());
m_instanceTypeHasBeenSet = true;
}
XmlNode placementNode = resultNode.FirstChild("placement");
if(!placementNode.IsNull())
{
m_placement = placementNode;
m_placementHasBeenSet = true;
}
XmlNode kernelIdNode = resultNode.FirstChild("kernelId");
if(!kernelIdNode.IsNull())
{
m_kernelId = StringUtils::Trim(kernelIdNode.GetText().c_str());
m_kernelIdHasBeenSet = true;
}
XmlNode ramdiskIdNode = resultNode.FirstChild("ramdiskId");
if(!ramdiskIdNode.IsNull())
{
m_ramdiskId = StringUtils::Trim(ramdiskIdNode.GetText().c_str());
m_ramdiskIdHasBeenSet = true;
}
XmlNode blockDeviceMappingsNode = resultNode.FirstChild("blockDeviceMapping");
if(!blockDeviceMappingsNode.IsNull())
{
XmlNode blockDeviceMappingsMember = blockDeviceMappingsNode.FirstChild("item");
while(!blockDeviceMappingsMember.IsNull())
{
m_blockDeviceMappings.push_back(blockDeviceMappingsMember);
blockDeviceMappingsMember = blockDeviceMappingsMember.NextNode("item");
}
m_blockDeviceMappingsHasBeenSet = true;
}
XmlNode subnetIdNode = resultNode.FirstChild("subnetId");
if(!subnetIdNode.IsNull())
{
m_subnetId = StringUtils::Trim(subnetIdNode.GetText().c_str());
m_subnetIdHasBeenSet = true;
}
XmlNode networkInterfacesNode = resultNode.FirstChild("networkInterfaceSet");
if(!networkInterfacesNode.IsNull())
{
XmlNode networkInterfacesMember = networkInterfacesNode.FirstChild("item");
while(!networkInterfacesMember.IsNull())
{
m_networkInterfaces.push_back(networkInterfacesMember);
networkInterfacesMember = networkInterfacesMember.NextNode("item");
}
m_networkInterfacesHasBeenSet = true;
}
XmlNode iamInstanceProfileNode = resultNode.FirstChild("iamInstanceProfile");
if(!iamInstanceProfileNode.IsNull())
{
m_iamInstanceProfile = iamInstanceProfileNode;
//.........这里部分代码省略.........
示例14: while
DeleteFlowLogsResponse& DeleteFlowLogsResponse::operator =(const Aws::AmazonWebServiceResult<XmlDocument>& result)
{
const XmlDocument& xmlDocument = result.GetPayload();
XmlNode rootNode = xmlDocument.GetRootElement();
XmlNode resultNode = rootNode;
if (!rootNode.IsNull() && (rootNode.GetName() != "DeleteFlowLogsResponse"))
{
resultNode = rootNode.FirstChild("DeleteFlowLogsResponse");
}
if(!resultNode.IsNull())
{
XmlNode unsuccessfulNode = resultNode.FirstChild("unsuccessful");
if(!unsuccessfulNode.IsNull())
{
XmlNode unsuccessfulMember = unsuccessfulNode.FirstChild("item");
while(!unsuccessfulMember.IsNull())
{
m_unsuccessful.push_back(unsuccessfulMember);
unsuccessfulMember = unsuccessfulMember.NextNode("item");
}
}
}
if (!rootNode.IsNull()) {
XmlNode requestIdNode = rootNode.FirstChild("requestId");
if (!requestIdNode.IsNull())
{
m_responseMetadata.SetRequestId(StringUtils::Trim(requestIdNode.GetText().c_str()));
}
AWS_LOGSTREAM_DEBUG("Aws::EC2::Model::DeleteFlowLogsResponse", "x-amzn-request-id: " << m_responseMetadata.GetRequestId() );
}
return *this;
}
示例15: while
ReservedCacheNode& ReservedCacheNode::operator =(const XmlNode& xmlNode)
{
XmlNode resultNode = xmlNode;
if(!resultNode.IsNull())
{
XmlNode reservedCacheNodeIdNode = resultNode.FirstChild("ReservedCacheNodeId");
if(!reservedCacheNodeIdNode.IsNull())
{
m_reservedCacheNodeId = StringUtils::Trim(reservedCacheNodeIdNode.GetText().c_str());
m_reservedCacheNodeIdHasBeenSet = true;
}
XmlNode reservedCacheNodesOfferingIdNode = resultNode.FirstChild("ReservedCacheNodesOfferingId");
if(!reservedCacheNodesOfferingIdNode.IsNull())
{
m_reservedCacheNodesOfferingId = StringUtils::Trim(reservedCacheNodesOfferingIdNode.GetText().c_str());
m_reservedCacheNodesOfferingIdHasBeenSet = true;
}
XmlNode cacheNodeTypeNode = resultNode.FirstChild("CacheNodeType");
if(!cacheNodeTypeNode.IsNull())
{
m_cacheNodeType = StringUtils::Trim(cacheNodeTypeNode.GetText().c_str());
m_cacheNodeTypeHasBeenSet = true;
}
XmlNode startTimeNode = resultNode.FirstChild("StartTime");
if(!startTimeNode.IsNull())
{
m_startTime = StringUtils::ConvertToDouble(StringUtils::Trim(startTimeNode.GetText().c_str()).c_str());
m_startTimeHasBeenSet = true;
}
XmlNode durationNode = resultNode.FirstChild("Duration");
if(!durationNode.IsNull())
{
m_duration = StringUtils::ConvertToInt32(StringUtils::Trim(durationNode.GetText().c_str()).c_str());
m_durationHasBeenSet = true;
}
XmlNode fixedPriceNode = resultNode.FirstChild("FixedPrice");
if(!fixedPriceNode.IsNull())
{
m_fixedPrice = StringUtils::ConvertToDouble(StringUtils::Trim(fixedPriceNode.GetText().c_str()).c_str());
m_fixedPriceHasBeenSet = true;
}
XmlNode usagePriceNode = resultNode.FirstChild("UsagePrice");
if(!usagePriceNode.IsNull())
{
m_usagePrice = StringUtils::ConvertToDouble(StringUtils::Trim(usagePriceNode.GetText().c_str()).c_str());
m_usagePriceHasBeenSet = true;
}
XmlNode cacheNodeCountNode = resultNode.FirstChild("CacheNodeCount");
if(!cacheNodeCountNode.IsNull())
{
m_cacheNodeCount = StringUtils::ConvertToInt32(StringUtils::Trim(cacheNodeCountNode.GetText().c_str()).c_str());
m_cacheNodeCountHasBeenSet = true;
}
XmlNode productDescriptionNode = resultNode.FirstChild("ProductDescription");
if(!productDescriptionNode.IsNull())
{
m_productDescription = StringUtils::Trim(productDescriptionNode.GetText().c_str());
m_productDescriptionHasBeenSet = true;
}
XmlNode offeringTypeNode = resultNode.FirstChild("OfferingType");
if(!offeringTypeNode.IsNull())
{
m_offeringType = StringUtils::Trim(offeringTypeNode.GetText().c_str());
m_offeringTypeHasBeenSet = true;
}
XmlNode stateNode = resultNode.FirstChild("State");
if(!stateNode.IsNull())
{
m_state = StringUtils::Trim(stateNode.GetText().c_str());
m_stateHasBeenSet = true;
}
XmlNode recurringChargesNode = resultNode.FirstChild("RecurringCharges");
if(!recurringChargesNode.IsNull())
{
XmlNode recurringChargesMember = recurringChargesNode.FirstChild("RecurringCharge");
while(!recurringChargesMember.IsNull())
{
m_recurringCharges.push_back(recurringChargesMember);
recurringChargesMember = recurringChargesMember.NextNode("RecurringCharge");
}
m_recurringChargesHasBeenSet = true;
}
}
return *this;
}