Example #1
0
 public static void Test_telechargement_plus_loadPostFromWeb_05(string minTime = null, bool reload = false, bool loadImage = false)
 {
     TelechargementPlusInit();
     MongoCollection<BsonDocument> collection = TelechargementPlus_GetMongoCollection();
     IMongoQuery query = null;
     if (minTime != null)
         // minTime "2013-11-07 14:00"
         query = Query.GTE("creationDate", new BsonDateTime(DateTime.ParseExact(minTime, "yyyy-MM-dd HH:mm", CultureInfo.CurrentCulture)));
     IMongoSortBy sort = SortBy.Descending("creationDate");
     MongoCursor<BsonDocument> cursor;
     if (query != null)
         cursor = collection.Find(query);
     else
         cursor = collection.FindAll();
     var q = from doc in cursor.SetSortOrder(sort) select from print in TelechargementPlus_LoadPost_v1.GetPrints(doc.zGetString("url"), reload: reload, loadImage: loadImage) select print;
     //RunSource.CurrentRunSource.View(q);
     q.zView();
 }
Example #2
0
        public static void Test_telechargement_plus_loadPostFromWeb_01(bool reload = false, bool loadImage = false)
        {
            Trace.WriteLine("Test_telechargement_plus_loadPostFromWeb_01");
            //string url = "http://www.telechargement-plus.com/e-book-magazines/87209-les-cahiers-du-monde-de-lintelligence-n-2-novembre-dycembre-2013-janvier-2014-lien-direct.html";
            //string url = "http://www.telechargement-plus.com/e-book-magazines/livres/87422-medecine-3e-partie.html";   // 3 liens uploaded
            //string url = "http://www.telechargement-plus.com/e-book-magazines/88218-solutions-pc-n8-septembre-2013-liens-direct.html";
            //string url = "http://www.telechargement-plus.com/e-book-magazines/livres/87000-60-petits-maux-soignys-par-les-huiles-essentielles.html";   // pb liens dans description
            string url = "http://www.telechargement-plus.com/e-book-magazines/journaux/91392-midi-olympique-du-08-novembre-2013-multi.html";  // image uploaded
            //string url = "";
            //string url = "";
            //string url = "";
            //FrboardInit();
            //LoadFrboardPost post = new LoadFrboardPost(url);
            //post.LoadFromWeb(loadImage);
            //RunSource.CurrentRunSource.View(post.Post);
            //RunSource.CurrentRunSource.View(post.Prints);

            //LoadTelechargementPlusPost loadPost = new LoadTelechargementPlusPost(url);
            //HttpLoad load = new HttpLoad(loadPost);
            //load.LoadFromWeb(loadImage);

            TelechargementPlusInit();
            TelechargementPlus_LoadPost_v1 loadPost = new TelechargementPlus_LoadPost_v1(url);

            loadPost.Load(reload: reload, loadImage: loadImage);
            //RunSource.CurrentRunSource.View(loadPost.Post);
            //RunSource.CurrentRunSource.View(loadPost.Prints);
            loadPost.Prints.zView();

            //loadPost.SaveXml(reload: true);

            //loadPost.LoadFromWeb(loadImage);
            //RunSource.CurrentRunSource.View(loadPost.Prints);

            //LoadTelechargementPlusPostFromWeb loadPost = new LoadTelechargementPlusPostFromWeb(url, loadImage: loadImage);
            //RunSource.CurrentRunSource.View(loadPost);
        }
Example #3
0
 public static void Test_telechargement_plus_loadPostFromWeb_02(bool reload = false, int startPage = 1, int maxPage = 1, bool loadImage = false)
 {
     Trace.WriteLine("Test_telechargement_plus_loadPostFromWeb_02");
     TelechargementPlusInit();
     //RunSource.CurrentRunSource.View(from postHeader in new TelechargementPlus_LoadPostHeaderFromWeb_v1(startPage: startPage, maxPage: maxPage) select from print in TelechargementPlus_LoadPost_v1.GetPrints(postHeader.url, reload, loadImage) select print);
     (from postHeader in new TelechargementPlus_LoadPostHeaderFromWeb_v1(startPage: startPage, maxPage: maxPage) select from print in TelechargementPlus_LoadPost_v1.GetPrints(postHeader.url, reload, loadImage) select print).zView();
 }