Exemple #1
0
        public List <T> GetEntityList(string html, ParseConfig config)
        {
            TSave_M tsave_m = config.Page.TSave_M;

            if (tsave_m == null)
            {
                throw new ArgumentNullException(tsave_m.GetType().Name);
            }
            HtmlDocument doc = new HtmlDocument();

            doc.LoadHtml(html);
            List <T> obj = AnalyzeTSave_M(tsave_m, doc);

            return(obj);
        }
Exemple #2
0
        public T GetEntity(string html, ParseConfig config)
        {
            TSave tsave = config.Page.TSave;

            if (tsave == null)
            {
                throw new ArgumentNullException(tsave.GetType().Name);
            }

            HtmlDocument doc = new HtmlDocument();

            doc.LoadHtml(html);
            T obj = AnalyzeTSave(tsave, doc);

            return(obj);
        }