def __init__(self) -> None:
HTMLParser.__init__(self)
self.galleries: typing.Set[str] = set()
self.stop_at_favorites: int = 0
python类__init__()的实例源码
def __init__(self) -> None:
HTMLParser.__init__(self)
self.empty_search = 0
def __init__(self) -> None:
HTMLParser.__init__(self, convert_charrefs=True)
self.torrent_link = ''
self.stop_at_found: int = 0
self.found_non_final_gallery: int = 0
self.parent_gallery: str = ''
self.found_parent_gallery: int = 0
self.found_gallery_link: int = 0
self.non_final_gallery: str = ''
def __init__(self) -> None:
HTMLParser.__init__(self, convert_charrefs=True)
self.torrent = ''
self.found_seed_data = 0
self.found_posted_data = 0
self.posted_date = ''
self.seeds = 0
def __init__(self) -> None:
HTMLParser.__init__(self)
self.archive = ''
def __init__(self, **kwargs):
HTMLParser.__init__(self)
self.kwargs = kwargs
self.tables = []
self.last_row = []
self.rows = []
self.max_row_width = 0
self.active = None
self.last_content = ""
self.is_last_row_header = False
def __init__(self, allows = []):
HTMLParser.__init__(self)
self.allow_tags = allows if allows else self.allow_tags
self.result = []
self.start = []
self.data = []
def __init__(self, lang):
self.lang = lang # lang of the word we are looking up
self.in_lang = False # flag: are we in the appropriate language?
self.getting_defs = False # flag: are we collecting definitions?
self.pos = "" # part of speech we are in
self.trans = {} # each key is the pos, each entry the translations
HTMLParser.__init__(self)
def __init__(self, *args, **kwargs):
HTMLParser.__init__(self, *args, **kwargs)
# Keep a list of empty-element tags that were encountered
# without an explicit closing tag. If we encounter a closing tag
# of this type, we'll associate it with one of those entries.
#
# This isn't a stack because we don't care about the
# order. It's a list of closing tags we've already handled and
# will ignore, assuming they ever show up.
self.already_closed_empty_element = []
def __init__(self, *args, **kwargs):
if CONSTRUCTOR_TAKES_STRICT and not CONSTRUCTOR_STRICT_IS_DEPRECATED:
kwargs['strict'] = False
if CONSTRUCTOR_TAKES_CONVERT_CHARREFS:
kwargs['convert_charrefs'] = False
self.parser_args = (args, kwargs)
def __init__(self):
HTMLParser.__init__(self)
self.count = 0
self.id = None
def __init__(self, url, with_subdomain=False):
HTMLParser.__init__(self)
self.protocol, self.domain, self.path = self.parse_url(url)
self.with_subdomain = with_subdomain
self.links = set()
def __init__(self, level):
"""Initialize attributes."""
self.level = level # header level of the element, e.g. 1 for <h1>, 2 for <h2>, etc
self.id = '' # anchor id (in-page link), used in 'id' and 'href' attribute of 'a' tag
self.text = '' # pure text content of header tag, e.g. 'Title' for '<h1>Title</h1>'
self.inner_html = '' # inner HTML
self.father = None # point to the direct father node
self.children = [] # elements with lower levels that directly follows the current elem
def __init__(self, *args, **kwargs):
HTMLParser.__init__(self, *args, **kwargs)
# Keep a list of empty-element tags that were encountered
# without an explicit closing tag. If we encounter a closing tag
# of this type, we'll associate it with one of those entries.
#
# This isn't a stack because we don't care about the
# order. It's a list of closing tags we've already handled and
# will ignore, assuming they ever show up.
self.already_closed_empty_element = []
def __init__(self, *args, **kwargs):
if CONSTRUCTOR_TAKES_STRICT and not CONSTRUCTOR_STRICT_IS_DEPRECATED:
kwargs['strict'] = False
if CONSTRUCTOR_TAKES_CONVERT_CHARREFS:
kwargs['convert_charrefs'] = False
self.parser_args = (args, kwargs)
def __init__(self):
HTMLParser.__init__(self)
self._level = 0
self._last = ''
self._in_code = False
self._prettified = [_BASE_HTML_HEADER]
def __init__(self, value=None):
self._value = value
def __init__(self):
HTMLParser.__init__(self)
self.lectures = 0
def __init__(self):
HTMLParser.__init__(self)
prettytable.py 文件源码
项目:My-Web-Server-Framework-With-Python2.7
作者: syjsu
项目源码
文件源码
阅读 32
收藏 0
点赞 0
评论 0
def __init__(self, **kwargs):
HTMLParser.__init__(self)
self.kwargs = kwargs
self.tables = []
self.last_row = []
self.rows = []
self.max_row_width = 0
self.active = None
self.last_content = ""
self.is_last_row_header = False