public async Task CheckAll(Action <IManga> status) { var all = _dbContext.GetMangasFrom(DbName); var rss = await _webParser.GetRssFeedAsync("http://mangastream.com/rss"); if (rss == null) { return; } rss.Reverse(); var openlink = _dbContext.GetOpenLinks(); foreach (var manga in all) { foreach (var rssItemObject in rss) { status.Invoke(manga); if (!rssItemObject.Title.ToLower().Contains(manga.Name.ToLower())) { continue; } var nc = rssItemObject.Title.ToLower().Replace(manga.Name.ToLower(), string.Empty).Trim(); var isNew = _newChapterHelper.IsNew(manga, nc, rssItemObject.PubDate, rssItemObject.Link, openlink); } } }
public async Task CheckAll(Action <IManga> status) { var all = _dbContext.GetMangasFrom(DbName); var openlink = _dbContext.GetOpenLinks(); foreach (var manga in all) { status.Invoke(manga); var rss = await _webParser.GetRssFeedAsync(manga.Rss); if (rss == null) { continue; } rss.Reverse(); foreach (var rssItemObject in rss) { var title = rssItemObject.Title; var nc = Regex.Match(title, @"(?<other>ep\.|episode ) ?(?<chapter>\d+.?\d+|[0-9])", RegexOptions.IgnoreCase); var ch = nc.Groups["chapter"].Value; if (string.IsNullOrWhiteSpace(ch)) { ch = rssItemObject.Title; } var isNew = _newChapterHelper.IsNew(manga, ch.Trim('.').Trim(), rssItemObject.PubDate, rssItemObject.Link, openlink); } } }
public async Task CheckAll(Action <IManga> status) { var all = _dbContext.GetMangasFrom(DbName); var openlink = _dbContext.GetOpenLinks(); foreach (var manga in all) { status.Invoke(manga); if (string.IsNullOrEmpty(manga.Rss)) { _logger.Log.Warn($"MANGAFOX {manga.Name} missing rss feed link"); continue; } var rss = await _webParser.GetRssFeedAsync(manga.Rss); if (rss == null) { continue; } rss.Reverse(); foreach (var rssItemObject in rss) { // sample title => Boku no Hero Academia Vol TBD Ch 125 var re = Regex.Match(rssItemObject.Title, @"(?<name>.+)(?<vol>[vol tbd0-9]+)?[ch ]+?(?<chapter>[0-9\.]+)", RegexOptions.IgnoreCase); var nc = string.IsNullOrEmpty(re.Groups["chapter"].Value) ? rssItemObject.Title.Replace(manga.Name.ToLower(), string.Empty) : re.Groups["chapter"].Value.Trim('.').Trim(); var isNew = _newChapterHelper.IsNew(manga, nc, rssItemObject.PubDate, rssItemObject.Link, openlink); await Task.Delay(100); } } }
public async Task CheckAll(Action <IManga> status) { var all = _dbContext.GetMangasFrom(DbName); var openlink = _dbContext.GetOpenLinks(); foreach (var manga in all) { status.Invoke(manga); var rss = await _webParser.GetRssFeedAsync(manga.Rss); if (rss == null) { continue; } rss.Reverse(); foreach (var rssItemObject in rss) { var nc = rssItemObject.Title.ToLower().Replace($"{manga.Name.ToLower()} chapter", string.Empty).Trim(); if (nc.Contains(" ")) { nc = nc.Split(new[] { ' ' }, StringSplitOptions.RemoveEmptyEntries)[0]; } var isNew = _newChapterHelper.IsNew(manga, nc, rssItemObject.PubDate, rssItemObject.Link, openlink); } } }
public async Task CheckAll(Action <IManga> status) { // /en/0/87/5/ == 87.5 // /en/0/24/ == 24 var all = _dbContext.GetMangasFrom(DbName); var openlink = _dbContext.GetOpenLinks(); var rss = await _webParser.GetRssFeedAsync("http://sensescans.com/reader/feeds/rss/"); if (rss == null) { return; } rss.Reverse(); foreach (var manga in all) { foreach (var rssItemObject in rss) { status.Invoke(manga); if (!rssItemObject.Title.ToLower().Contains(manga.Name.ToLower())) { continue; } var ncs = rssItemObject.Title.ToLower().Replace(manga.Name.ToLower(), string.Empty); var nc = Regex.Match(ncs.Trim(), @"(?<vol>vol\.\d+)? ?(?<chapter>(chapter)?[0-9\.]+)(.+)?:?(?<chaptername>.+)?", RegexOptions.IgnoreCase).Groups["chapter"].Value.Trim('.').Trim(); if (string.IsNullOrEmpty(nc)) { nc = ncs; } var isNew = _newChapterHelper.IsNew(manga, nc, rssItemObject.PubDate, rssItemObject.Link, openlink); } } }
public async Task CheckAll(Action <IManga> status) { var all = _dbContext.GetMangasFrom(DbName); var openlink = _dbContext.GetOpenLinks(); foreach (var manga in all) { status.Invoke(manga); if (string.IsNullOrEmpty(manga.BaseMangaLink)) { continue; } var html = await _webParser.GetHtmlSourceDocumentAsync(manga.BaseMangaLink.TrimEnd('/')); if (html == null) { continue; } var tr = html.All.Where( t => t.LocalName == "tr" && t.Children.Length == 2 && t.Children[0].InnerHtml.Contains("chico")); foreach (var element in tr) { var title = element.Children[0].Children[1].TextContent.Trim(); if (title.Contains("Chapter Name")) { continue; } var newDate = DateTime.Parse(element.Children[1].TextContent.Trim('\n').Trim(), CultureInfo.InvariantCulture); var link = "http://mangareader.net" + element.Children[0].Children[1].GetAttribute("href"); if (!title.ToLower().Contains(manga.Name.ToLower())) { continue; } var nc = title.ToLower().Replace(manga.Name.ToLower(), string.Empty).Trim(); if (nc.Contains(" ")) { nc = nc.Split(new[] { ' ' }, StringSplitOptions.RemoveEmptyEntries)[0]; } var isNew = _newChapterHelper.IsNew(manga, nc, newDate, link, openlink); } await Task.Delay(500); } }
public async Task CheckAll(Action <IManga> status) { var all = _dbContext.GetMangasFrom(DbName); var openlink = _dbContext.GetOpenLinks(); foreach (var manga in all) { status.Invoke(manga); var html = await _webParser.GetHtmlSourceDocumentAsync(manga.BaseMangaLink); if (html == null) { continue; } var tr = html.All.Where(t => t.LocalName == "tr" && t.Children.Length == 2); foreach (var element in tr.Reverse()) { var title = element.Children[0].TextContent.Trim(); if (title.Contains("Chapter Name")) { continue; } var newDate = DateTime.Parse(element.Children[1].TextContent.Trim('\n').Trim(), CultureInfo.InvariantCulture); var link = "http://kissmanga.com" + element.Children[0].Children[0].GetAttribute("href"); if (!title.ToLower().Contains(manga.Name.ToLower())) { continue; } var nc = title.ToLower().Replace($"{manga.Name.ToLower()}", string.Empty).Trim(); var nnc = Regex.Match(nc, @"(ch\. | chapter )?(\d+\.?\d+):?(.+)?", RegexOptions.IgnoreCase); var ch = nnc.Groups[2].Value; if (string.IsNullOrWhiteSpace(ch)) { ch = nnc.Groups[0].Value; } var isNew = _newChapterHelper.IsNew(manga, ch, newDate, link, openlink); } await Task.Delay(500); } }
public async Task CheckAll(Action <IManga> status) { var all = _dbContext.GetMangasFrom(DbName); var openlink = _dbContext.GetOpenLinks(); var m = await _load2Pages("https://www.heymanga.me/latest-manga/"); if (m == null) { return; } var m2 = await _load2Pages("https://www.heymanga.me/latest-manga/2"); if (m2 != null) { foreach (var d in m2) { if (m.Keys.Contains(d.Key)) { continue; } m.Add(d.Key, d.Value); } } foreach (var manga in all) { foreach (var rssItemObject in m) { status.Invoke(manga); if (!rssItemObject.Value.ToLower().Contains(manga.Name.ToLower())) { continue; } var nc = rssItemObject.Value.ToLower().Replace(manga.Name.ToLower(), string.Empty).Trim(); if (nc.Contains(" ")) { nc = nc.Split(new[] { ' ' }, StringSplitOptions.RemoveEmptyEntries)[0]; } var isNew = _newChapterHelper.IsNew(manga, nc, DateTime.Now, rssItemObject.Key, openlink); } } }
public async Task CheckAll(Action <IManga> status) { // /en/0/87/5/ == 87.5 // /en/0/24/ == 24 var all = _dbContext.GetMangasFrom(DbName); var openlink = _dbContext.GetOpenLinks(); var rss = await _webParser.GetRssFeedAsync("https://jaiminisbox.com/reader/feeds/rss"); if (rss == null) { return; } rss.Reverse(); foreach (var manga in all) { foreach (var rssItemObject in rss) { status.Invoke(manga); if (!rssItemObject.Title.ToLower().Contains(manga.Name.ToLower())) { continue; } var ncs = rssItemObject.Link.Split(new[] { '/' }, StringSplitOptions.RemoveEmptyEntries); string nc; if (ncs[ncs.Length - 4] == "en") { nc = $"{ncs[ncs.Length - 2]}.{ncs[ncs.Length - 1]}"; } else if (ncs[ncs.Length - 3] == "en") { nc = $"{ncs.Last()}"; } else { continue; } var isNew = _newChapterHelper.IsNew(manga, nc, rssItemObject.PubDate, rssItemObject.Link, openlink); } } }
//http://read.tomochan.today/rss public async Task CheckAll(Action <IManga> status) { var all = _dbContext.GetMangasFrom(DbName); var rss = await _webParser.GetRssFeedAsync("http://read.tomochan.today/rss"); if (rss == null) { return; } rss.Reverse(); var openlink = _dbContext.GetOpenLinks(); foreach (var manga in all) { foreach (var rssItemObject in rss) { status.Invoke(manga); var isNew = _newChapterHelper.IsNew(manga, rssItemObject.Category, rssItemObject.PubDate, rssItemObject.Link, openlink); await Task.Delay(100); } } }
public async Task CheckAll(Action <IManga> status) { var all = _dbContext.GetMangasFrom(DbName); var brss = _dbContext.GetSettingsFor("Batoto Rss"); var rss = await _webParser.GetRssFeedAsync(brss.Link); if (rss == null) { return; } rss.Reverse(); var openlink = _dbContext.GetOpenLinks(); foreach (var manga in all) { foreach (var rssItemObject in rss) { // example title Jitsu wa Watashi wa - English - Vol.18 Ch.156: Aizawa Nagisa and Aizawa Nagisa② status.Invoke(manga); if (!rssItemObject.Title.ToLower().Contains(manga.Name.ToLower())) { continue; } var ncn = Regex.Match(rssItemObject.Title, @"(?<manga>.+) - .+ - ?([vol]+\.[0-9\.]+)? [ch\.]+?(?<chapter>[0-9\.]+)(\(.+\))?:?(?<chaptername>.+)", RegexOptions.IgnoreCase); var ch = ncn.Groups["chapter"]?.Value.Trim() ?? ncn.Groups["chaptername"]?.Value.Trim(); if (string.IsNullOrEmpty(ch)) { _logger.Log.Warn($"var ch={ch}, var Rss title={rssItemObject.Title}"); continue; } var isNew = _newChapterHelper.IsNew(manga, ch.Trim('.'), rssItemObject.PubDate, rssItemObject.Link, openlink); } } }