Пример #1
0
 public bool? getAuthStatisticsNextPage(string authUrl, ref SG.Author author)
 {
     bool isOK = true;
     setts = setRecords.ReadSettings();
     int maxResults = setts.GSMaxResults;
     int num = author.getNumberOfPapers();
     if (num < 0) return false;
     if (num % 100 != 0) return false;
     if (num >= maxResults) return false;
     authUrl += ("&pagesize=100&cstart=" + num);
     GSAuthScraper authScraper = new GSAuthScraper(authUrl, num, ref isOK);
     if (!isOK) return null;
     List<SG.Paper> papers = authScraper.getPapersOfCurrentPage();
     if (papers == null) return null;
     if (papers.Count == 0) return false;
     foreach (SG.Paper paper in papers)
     {
         if (num == maxResults) return false;
         author.addPaper(paper);
         num++;
     }
     return true;
 }
Пример #2
0
 // RESULTS FROM AUTHOR PROFILE PAGE
 public SG.Author getAuthStatistics(string authUrl)
 {
     bool isOK = true;
     if (authUrl == null) return null;
     authUrl += "&pagesize=100";
     GSAuthScraper authScraper = new GSAuthScraper(authUrl, 0,ref isOK);
     if (!isOK) return null;
     authScraper.getCitationStats();
     SG.Author author = new SG.Author(authScraper.getName(), authScraper.getAffiliation(), authScraper.getHomePage(), authScraper.getHIndex(), authScraper.getIIndex());
     //Console.WriteLine(author.Name + "," + author.getHIndex() + "," + author.getI10Index());
     List<SG.Paper> papers = authScraper.getPapersOfCurrentPage();
     if (papers == null) return null;
     if (papers.Count == 0) return author;
     foreach (SG.Paper paper in papers) author.addPaper(paper);
     return author;
 }