Exemple #1
0
 protected RJInfo(String rj, String html)
 {
     this.RJNum = rj;
     this.html  = html;
     this.p     = HTMLParser.GetByHTML(html);
     outline    = new RJOutline(html);
 }
Exemple #2
0
        public InfoGroup <BaseInfoType> GetAllInfos()
        {
            InfoGroup <BaseInfoType> info = new InfoGroup <BaseInfoType>(RJNum);
            RJOutline outline             = new RJOutline(html);
            Locale    l = outline.GetLocale();

            String cache = LocaleTexts.InLang("作品名", l);

            info.InfoList.Add(cache, new LiteralText(cache, GetWorkName()));

            cache = LocaleTexts.InLang("封面图", l);
            InfoGroup <Picture> pics = new InfoGroup <Picture>(cache);
            int i = 0;

            foreach (Image pic in GetImages())
            {
                pics.InfoList.Add((i).ToString(), new Picture(i.ToString(), pic));
                i++;
            }
            info.InfoList.Add(cache, pics);

            cache = LocaleTexts.InLang("社团名", l);
            TagCollection tc = new TagCollection(cache);

            tc.AddTag(new Tag(GetCircleName()));
            info.InfoList.Add(cache, tc);

            foreach (BaseInfoType inf in outline.ToInfoGroup())
            {
                info.InfoList.Add(inf.Name, inf);
            }

            cache = LocaleTexts.InLang("作品内容", l);
            info.InfoList.Add(cache, new LiteralText(cache, GetSummary()));

            cache = LocaleTexts.InLang("评价", l);
            info.InfoList.Add(cache, new LiteralText(cache, GetRating()));

            return(info);
        }