void fromMap()

in yuqing-20220301/include/alibabacloud/yuqing_20220301.hpp [1345:1611]


  void fromMap(map<string, boost::any> m) override {
    if (m.find("appName") != m.end() && !m["appName"].empty()) {
      appName = make_shared<string>(boost::any_cast<string>(m["appName"]));
    }
    if (m.find("appScore") != m.end() && !m["appScore"].empty()) {
      appScore = make_shared<long>(boost::any_cast<long>(m["appScore"]));
    }
    if (m.find("appStoreName") != m.end() && !m["appStoreName"].empty()) {
      appStoreName = make_shared<string>(boost::any_cast<string>(m["appStoreName"]));
    }
    if (m.find("atAuthorNames") != m.end() && !m["atAuthorNames"].empty()) {
      vector<string> toVec1;
      if (typeid(vector<boost::any>) == m["atAuthorNames"].type()) {
        vector<boost::any> vec1 = boost::any_cast<vector<boost::any>>(m["atAuthorNames"]);
        for (auto item:vec1) {
           toVec1.push_back(boost::any_cast<string>(item));
        }
      }
      atAuthorNames = make_shared<vector<string>>(toVec1);
    }
    if (m.find("audioCount") != m.end() && !m["audioCount"].empty()) {
      audioCount = make_shared<long>(boost::any_cast<long>(m["audioCount"]));
    }
    if (m.find("authorAvatarUrl") != m.end() && !m["authorAvatarUrl"].empty()) {
      authorAvatarUrl = make_shared<string>(boost::any_cast<string>(m["authorAvatarUrl"]));
    }
    if (m.find("authorFollowersCount") != m.end() && !m["authorFollowersCount"].empty()) {
      authorFollowersCount = make_shared<long>(boost::any_cast<long>(m["authorFollowersCount"]));
    }
    if (m.find("authorFriendsCount") != m.end() && !m["authorFriendsCount"].empty()) {
      authorFriendsCount = make_shared<long>(boost::any_cast<long>(m["authorFriendsCount"]));
    }
    if (m.find("authorGender") != m.end() && !m["authorGender"].empty()) {
      authorGender = make_shared<string>(boost::any_cast<string>(m["authorGender"]));
    }
    if (m.find("authorId") != m.end() && !m["authorId"].empty()) {
      authorId = make_shared<string>(boost::any_cast<string>(m["authorId"]));
    }
    if (m.find("authorLikesCount") != m.end() && !m["authorLikesCount"].empty()) {
      authorLikesCount = make_shared<long>(boost::any_cast<long>(m["authorLikesCount"]));
    }
    if (m.find("authorName") != m.end() && !m["authorName"].empty()) {
      authorName = make_shared<string>(boost::any_cast<string>(m["authorName"]));
    }
    if (m.find("authorProfileUrl") != m.end() && !m["authorProfileUrl"].empty()) {
      authorProfileUrl = make_shared<string>(boost::any_cast<string>(m["authorProfileUrl"]));
    }
    if (m.find("authorStatusesCount") != m.end() && !m["authorStatusesCount"].empty()) {
      authorStatusesCount = make_shared<long>(boost::any_cast<long>(m["authorStatusesCount"]));
    }
    if (m.find("authorVerified") != m.end() && !m["authorVerified"].empty()) {
      authorVerified = make_shared<bool>(boost::any_cast<bool>(m["authorVerified"]));
    }
    if (m.find("authorVerifyType") != m.end() && !m["authorVerifyType"].empty()) {
      authorVerifyType = make_shared<long>(boost::any_cast<long>(m["authorVerifyType"]));
    }
    if (m.find("contentAudioText") != m.end() && !m["contentAudioText"].empty()) {
      contentAudioText = make_shared<string>(boost::any_cast<string>(m["contentAudioText"]));
    }
    if (m.find("contentAudioUrls") != m.end() && !m["contentAudioUrls"].empty()) {
      contentAudioUrls = make_shared<string>(boost::any_cast<string>(m["contentAudioUrls"]));
    }
    if (m.find("contentImageText") != m.end() && !m["contentImageText"].empty()) {
      contentImageText = make_shared<string>(boost::any_cast<string>(m["contentImageText"]));
    }
    if (m.find("contentImageUrls") != m.end() && !m["contentImageUrls"].empty()) {
      contentImageUrls = make_shared<string>(boost::any_cast<string>(m["contentImageUrls"]));
    }
    if (m.find("contentLang") != m.end() && !m["contentLang"].empty()) {
      contentLang = make_shared<string>(boost::any_cast<string>(m["contentLang"]));
    }
    if (m.find("contentLen") != m.end() && !m["contentLen"].empty()) {
      contentLen = make_shared<long>(boost::any_cast<long>(m["contentLen"]));
    }
    if (m.find("contentVideoText") != m.end() && !m["contentVideoText"].empty()) {
      contentVideoText = make_shared<string>(boost::any_cast<string>(m["contentVideoText"]));
    }
    if (m.find("contentVideoUrls") != m.end() && !m["contentVideoUrls"].empty()) {
      contentVideoUrls = make_shared<string>(boost::any_cast<string>(m["contentVideoUrls"]));
    }
    if (m.find("createTime") != m.end() && !m["createTime"].empty()) {
      createTime = make_shared<long>(boost::any_cast<long>(m["createTime"]));
    }
    if (m.find("docAnswersCount") != m.end() && !m["docAnswersCount"].empty()) {
      docAnswersCount = make_shared<long>(boost::any_cast<long>(m["docAnswersCount"]));
    }
    if (m.find("docAreas") != m.end() && !m["docAreas"].empty()) {
      vector<string> toVec1;
      if (typeid(vector<boost::any>) == m["docAreas"].type()) {
        vector<boost::any> vec1 = boost::any_cast<vector<boost::any>>(m["docAreas"]);
        for (auto item:vec1) {
           toVec1.push_back(boost::any_cast<string>(item));
        }
      }
      docAreas = make_shared<vector<string>>(toVec1);
    }
    if (m.find("docCoinCount") != m.end() && !m["docCoinCount"].empty()) {
      docCoinCount = make_shared<long>(boost::any_cast<long>(m["docCoinCount"]));
    }
    if (m.find("docCommentsCount") != m.end() && !m["docCommentsCount"].empty()) {
      docCommentsCount = make_shared<long>(boost::any_cast<long>(m["docCommentsCount"]));
    }
    if (m.find("docContent") != m.end() && !m["docContent"].empty()) {
      docContent = make_shared<string>(boost::any_cast<string>(m["docContent"]));
    }
    if (m.find("docContentBrief") != m.end() && !m["docContentBrief"].empty()) {
      docContentBrief = make_shared<string>(boost::any_cast<string>(m["docContentBrief"]));
    }
    if (m.find("docContentSign") != m.end() && !m["docContentSign"].empty()) {
      docContentSign = make_shared<string>(boost::any_cast<string>(m["docContentSign"]));
    }
    if (m.find("docId") != m.end() && !m["docId"].empty()) {
      docId = make_shared<string>(boost::any_cast<string>(m["docId"]));
    }
    if (m.find("docLikesCount") != m.end() && !m["docLikesCount"].empty()) {
      docLikesCount = make_shared<long>(boost::any_cast<long>(m["docLikesCount"]));
    }
    if (m.find("docPlayCount") != m.end() && !m["docPlayCount"].empty()) {
      docPlayCount = make_shared<long>(boost::any_cast<long>(m["docPlayCount"]));
    }
    if (m.find("docReadingCount") != m.end() && !m["docReadingCount"].empty()) {
      docReadingCount = make_shared<long>(boost::any_cast<long>(m["docReadingCount"]));
    }
    if (m.find("docReadsCount") != m.end() && !m["docReadsCount"].empty()) {
      docReadsCount = make_shared<long>(boost::any_cast<long>(m["docReadsCount"]));
    }
    if (m.find("docRepostsCount") != m.end() && !m["docRepostsCount"].empty()) {
      docRepostsCount = make_shared<long>(boost::any_cast<long>(m["docRepostsCount"]));
    }
    if (m.find("docReprintName") != m.end() && !m["docReprintName"].empty()) {
      docReprintName = make_shared<string>(boost::any_cast<string>(m["docReprintName"]));
    }
    if (m.find("docSelfContentSign") != m.end() && !m["docSelfContentSign"].empty()) {
      docSelfContentSign = make_shared<string>(boost::any_cast<string>(m["docSelfContentSign"]));
    }
    if (m.find("docTitle") != m.end() && !m["docTitle"].empty()) {
      docTitle = make_shared<string>(boost::any_cast<string>(m["docTitle"]));
    }
    if (m.find("docUrl") != m.end() && !m["docUrl"].empty()) {
      docUrl = make_shared<string>(boost::any_cast<string>(m["docUrl"]));
    }
    if (m.find("emotionScore") != m.end() && !m["emotionScore"].empty()) {
      emotionScore = make_shared<double>(boost::any_cast<double>(m["emotionScore"]));
    }
    if (m.find("emotionType") != m.end() && !m["emotionType"].empty()) {
      emotionType = make_shared<long>(boost::any_cast<long>(m["emotionType"]));
    }
    if (m.find("extInfo") != m.end() && !m["extInfo"].empty()) {
      map<string, string> map1 = boost::any_cast<map<string, string>>(m["extInfo"]);
      map<string, string> toMap1;
      for (auto item:map1) {
         toMap1[item.first] = item.second;
      }
      extInfo = make_shared<map<string, string>>(toMap1);
    }
    if (m.find("finEventCount") != m.end() && !m["finEventCount"].empty()) {
      finEventCount = make_shared<long>(boost::any_cast<long>(m["finEventCount"]));
    }
    if (m.find("financeEventList") != m.end() && !m["financeEventList"].empty()) {
      if (typeid(vector<boost::any>) == m["financeEventList"].type()) {
        vector<YuqingFinanceEvent> expect1;
        for(auto item1:boost::any_cast<vector<boost::any>>(m["financeEventList"])){
          if (typeid(map<string, boost::any>) == item1.type()) {
            YuqingFinanceEvent model2;
            model2.fromMap(boost::any_cast<map<string, boost::any>>(item1));
            expect1.push_back(model2);
          }
        }
        financeEventList = make_shared<vector<YuqingFinanceEvent>>(expect1);
      }
    }
    if (m.find("highlightKeywords") != m.end() && !m["highlightKeywords"].empty()) {
      vector<string> toVec1;
      if (typeid(vector<boost::any>) == m["highlightKeywords"].type()) {
        vector<boost::any> vec1 = boost::any_cast<vector<boost::any>>(m["highlightKeywords"]);
        for (auto item:vec1) {
           toVec1.push_back(boost::any_cast<string>(item));
        }
      }
      highlightKeywords = make_shared<vector<string>>(toVec1);
    }
    if (m.find("imageCount") != m.end() && !m["imageCount"].empty()) {
      imageCount = make_shared<long>(boost::any_cast<long>(m["imageCount"]));
    }
    if (m.find("influenceScore") != m.end() && !m["influenceScore"].empty()) {
      influenceScore = make_shared<double>(boost::any_cast<double>(m["influenceScore"]));
    }
    if (m.find("mediaHosts") != m.end() && !m["mediaHosts"].empty()) {
      vector<string> toVec1;
      if (typeid(vector<boost::any>) == m["mediaHosts"].type()) {
        vector<boost::any> vec1 = boost::any_cast<vector<boost::any>>(m["mediaHosts"]);
        for (auto item:vec1) {
           toVec1.push_back(boost::any_cast<string>(item));
        }
      }
      mediaHosts = make_shared<vector<string>>(toVec1);
    }
    if (m.find("mediaInfluenceLevel") != m.end() && !m["mediaInfluenceLevel"].empty()) {
      mediaInfluenceLevel = make_shared<long>(boost::any_cast<long>(m["mediaInfluenceLevel"]));
    }
    if (m.find("mediaName") != m.end() && !m["mediaName"].empty()) {
      mediaName = make_shared<string>(boost::any_cast<string>(m["mediaName"]));
    }
    if (m.find("mediaPropagationLevel") != m.end() && !m["mediaPropagationLevel"].empty()) {
      mediaPropagationLevel = make_shared<long>(boost::any_cast<long>(m["mediaPropagationLevel"]));
    }
    if (m.find("mediaType") != m.end() && !m["mediaType"].empty()) {
      mediaType = make_shared<string>(boost::any_cast<string>(m["mediaType"]));
    }
    if (m.find("messageType") != m.end() && !m["messageType"].empty()) {
      messageType = make_shared<string>(boost::any_cast<string>(m["messageType"]));
    }
    if (m.find("parentDocId") != m.end() && !m["parentDocId"].empty()) {
      parentDocId = make_shared<string>(boost::any_cast<string>(m["parentDocId"]));
    }
    if (m.find("propagationScore") != m.end() && !m["propagationScore"].empty()) {
      propagationScore = make_shared<double>(boost::any_cast<double>(m["propagationScore"]));
    }
    if (m.find("publishTime") != m.end() && !m["publishTime"].empty()) {
      publishTime = make_shared<long>(boost::any_cast<long>(m["publishTime"]));
    }
    if (m.find("relevanceScore") != m.end() && !m["relevanceScore"].empty()) {
      relevanceScore = make_shared<double>(boost::any_cast<double>(m["relevanceScore"]));
    }
    if (m.find("reportMaterialTags") != m.end() && !m["reportMaterialTags"].empty()) {
      vector<string> toVec1;
      if (typeid(vector<boost::any>) == m["reportMaterialTags"].type()) {
        vector<boost::any> vec1 = boost::any_cast<vector<boost::any>>(m["reportMaterialTags"]);
        for (auto item:vec1) {
           toVec1.push_back(boost::any_cast<string>(item));
        }
      }
      reportMaterialTags = make_shared<vector<string>>(toVec1);
    }
    if (m.find("repostList") != m.end() && !m["repostList"].empty()) {
      vector<string> toVec1;
      if (typeid(vector<boost::any>) == m["repostList"].type()) {
        vector<boost::any> vec1 = boost::any_cast<vector<boost::any>>(m["repostList"]);
        for (auto item:vec1) {
           toVec1.push_back(boost::any_cast<string>(item));
        }
      }
      repostList = make_shared<vector<string>>(toVec1);
    }
    if (m.find("similarNumber") != m.end() && !m["similarNumber"].empty()) {
      similarNumber = make_shared<long>(boost::any_cast<long>(m["similarNumber"]));
    }
    if (m.find("topics") != m.end() && !m["topics"].empty()) {
      vector<string> toVec1;
      if (typeid(vector<boost::any>) == m["topics"].type()) {
        vector<boost::any> vec1 = boost::any_cast<vector<boost::any>>(m["topics"]);
        for (auto item:vec1) {
           toVec1.push_back(boost::any_cast<string>(item));
        }
      }
      topics = make_shared<vector<string>>(toVec1);
    }
    if (m.find("videoCount") != m.end() && !m["videoCount"].empty()) {
      videoCount = make_shared<long>(boost::any_cast<long>(m["videoCount"]));
    }
    if (m.find("weiboCommentId") != m.end() && !m["weiboCommentId"].empty()) {
      weiboCommentId = make_shared<string>(boost::any_cast<string>(m["weiboCommentId"]));
    }
    if (m.find("weiboMid") != m.end() && !m["weiboMid"].empty()) {
      weiboMid = make_shared<string>(boost::any_cast<string>(m["weiboMid"]));
    }
  }