Update workflows/publish_pypi.yml
[manga-dl.git] / manga_py / providers / _template.py
blobf660f6e709735672dbdc93f553e9b8c6bd3121ba
1 from manga_py.provider import Provider
2 from .helpers.std import Std
5 class _Template(Provider, Std):
6 def get_archive_name(self) -> str:
7 """
8 Allows you to overload name generation. Method may be missing
9 """
11 def get_chapter_index(self) -> str:
12 """
13 Any string separated by "-"
14 Example: "1-3"
15 """
17 def get_content(self):
18 """
19 Called second. Returns the initial content to parse (just a cache)
20 Can be obtained using self.content
21 """
23 def get_manga_name(self) -> str:
24 """
25 String for the name of the manga directory
26 """
28 def get_chapters(self):
29 """
30 Should return an array of data (you can return the result of the self._elements ('css selector') method)
31 """
32 # return self._elements('a.chapter')
33 return []
35 def get_files(self):
36 """
37 Should return an array of strings (url of images)
38 """
39 return []
41 def get_cover(self) -> str:
42 """Not used now"""
43 # return self._cover_from_content('.cover img')
45 def book_meta(self) -> dict:
46 """
47 Not used now
48 :see http://acbf.wikia.com/wiki/Meta-data_Section_Definition
49 return {
50 'author': str,
51 'title': str,
52 'annotation': str,
53 'keywords': str,
54 'cover': str,
55 'rating': str,
57 """
59 def chapter_for_json(self) -> str:
60 """
61 overload std param, if need
62 If present, overloads getting chapter name for json dump
63 Should return a string
64 """
65 # return self.chapter
66 pass
69 main = _Template