Browse Source

Supported address for GetMediaMeta.

sdk-team 6 years ago
parent
commit
9df24cf9eb

+ 3 - 0
CHANGELOG

@@ -1,3 +1,6 @@
+2020-02-10 Version 1.36.251
+- Supported address for GetMediaMeta.
+
 2020-02-07 Version 1.36.250
 - Fix bug for DescribeZoneInfo, delete return result of reionId.
 - Fix bug for DeleteZone, parameter zoneId change to compulsory.

+ 1 - 1
VERSION

@@ -1 +1 @@
-1.36.250
+1.36.251

+ 10 - 0
imm/include/alibabacloud/imm/model/GetMediaMetaResult.h

@@ -36,6 +36,16 @@ namespace AlibabaCloud
 				{
 					struct MediaFormat
 					{
+						struct Address
+						{
+							std::string township;
+							std::string addressLine;
+							std::string country;
+							std::string city;
+							std::string district;
+							std::string province;
+						};
+						Address address;
 						int numberStreams;
 						std::string size;
 						std::string formatLongName;

+ 13 - 0
imm/src/model/GetMediaMetaResult.cc

@@ -61,6 +61,19 @@ void GetMediaMetaResult::parse(const std::string &payload)
 		mediaMeta_.mediaFormat.creationTime = mediaFormatNode["CreationTime"].asString();
 	if(!mediaFormatNode["Location"].isNull())
 		mediaMeta_.mediaFormat.location = mediaFormatNode["Location"].asString();
+	auto addressNode = mediaFormatNode["Address"];
+	if(!addressNode["AddressLine"].isNull())
+		mediaMeta_.mediaFormat.address.addressLine = addressNode["AddressLine"].asString();
+	if(!addressNode["Country"].isNull())
+		mediaMeta_.mediaFormat.address.country = addressNode["Country"].asString();
+	if(!addressNode["Province"].isNull())
+		mediaMeta_.mediaFormat.address.province = addressNode["Province"].asString();
+	if(!addressNode["City"].isNull())
+		mediaMeta_.mediaFormat.address.city = addressNode["City"].asString();
+	if(!addressNode["District"].isNull())
+		mediaMeta_.mediaFormat.address.district = addressNode["District"].asString();
+	if(!addressNode["Township"].isNull())
+		mediaMeta_.mediaFormat.address.township = addressNode["Township"].asString();
 	auto mediaStreamsNode = mediaMetaNode["MediaStreams"];
 	auto allVideoStreamsNode = mediaStreamsNode["VideoStreams"]["VideoStream"];
 	for (auto mediaStreamsNodeVideoStreamsVideoStream : allVideoStreamsNode)