2015-11-08 00:02:37 +01:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
|
2017-05-20 11:27:43 +02:00
|
|
|
# Copyright 2015-2017 Mike Fährmann
|
2015-11-08 00:02:37 +01:00
|
|
|
#
|
|
|
|
# This program is free software; you can redistribute it and/or modify
|
|
|
|
# it under the terms of the GNU General Public License version 2 as
|
|
|
|
# published by the Free Software Foundation.
|
|
|
|
|
2015-11-28 22:21:35 +01:00
|
|
|
"""Extract manga-chapters and entire manga from http://www.mangapanda.com/"""
|
2015-11-08 00:02:37 +01:00
|
|
|
|
2016-09-12 10:20:57 +02:00
|
|
|
from .mangareader import MangareaderMangaExtractor, MangareaderChapterExtractor
|
2015-11-08 00:02:37 +01:00
|
|
|
|
2017-02-01 00:53:19 +01:00
|
|
|
|
2016-09-12 10:20:57 +02:00
|
|
|
class MangapandaBase():
|
2015-11-28 22:21:35 +01:00
|
|
|
"""Base class for mangapanda extractors"""
|
2015-11-21 04:26:30 +01:00
|
|
|
category = "mangapanda"
|
2017-05-20 11:27:43 +02:00
|
|
|
root = "http://www.mangapanda.com"
|
2015-11-27 00:14:09 +01:00
|
|
|
|
|
|
|
|
2016-09-12 10:20:57 +02:00
|
|
|
class MangapandaMangaExtractor(MangapandaBase, MangareaderMangaExtractor):
|
2017-05-20 11:27:43 +02:00
|
|
|
"""Extractor for manga from mangapanda.com"""
|
|
|
|
pattern = [r"(?:https?://)?((?:www\.)?mangapanda\.com/[^/]+)$"]
|
2015-12-14 03:00:58 +01:00
|
|
|
test = [("http://www.mangapanda.com/mushishi", {
|
|
|
|
"url": "50a1ba730b85426b904da256c80f68ba6a8a2566",
|
|
|
|
})]
|
2015-11-27 00:14:09 +01:00
|
|
|
|
2017-02-01 00:53:19 +01:00
|
|
|
|
2016-09-12 10:20:57 +02:00
|
|
|
class MangapandaChapterExtractor(MangapandaBase, MangareaderChapterExtractor):
|
|
|
|
"""Extractor for manga-chapters from mangapanda.com"""
|
2015-11-30 01:11:13 +01:00
|
|
|
subcategory = "chapter"
|
2015-11-21 04:26:30 +01:00
|
|
|
pattern = [
|
2017-02-01 00:53:19 +01:00
|
|
|
(r"(?:https?://)?(?:www\.)?mangapanda\.com((/[^/]+)/(\d+))"),
|
|
|
|
(r"(?:https?://)?(?:www\.)?mangapanda\.com"
|
|
|
|
r"(/\d+-\d+-\d+(/[^/]+)/chapter-(\d+).html)"),
|
2015-11-21 04:26:30 +01:00
|
|
|
]
|
2015-12-14 03:00:58 +01:00
|
|
|
test = [("http://www.mangapanda.com/red-storm/2", {
|
|
|
|
"url": "4bf4ddf6c50105ec8a37675495ab80c46608275d",
|
2016-09-25 17:28:46 +02:00
|
|
|
"keyword": "89c712f7ed255ec9c1d8e84dcb5a160b6cb4498c",
|
2015-12-14 03:00:58 +01:00
|
|
|
})]
|