本文整理汇总了Python中settings.Settings.getInstance方法的典型用法代码示例。如果您正苦于以下问题:Python Settings.getInstance方法的具体用法?Python Settings.getInstance怎么用?Python Settings.getInstance使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类settings.Settings
的用法示例。
在下文中一共展示了Settings.getInstance方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
# 需要导入模块: from settings import Settings [as 别名]
# 或者: from settings.Settings import getInstance [as 别名]
def __init__(self):
self.settings = Settings.getInstance()
self.debug = self.settings.debug
self.htmlRetriever = HtmlRetriever.getInstance(self.settings.use_proxy)
if self.settings.save_pdflink:
self.pdfcache = PDFLinkSaver.getInstance()
self.author = re.compile('<div class="?gs_a"?>([^\\x00]+?) - ', re.I)
self.pdf_block = re.compile('<div class="?gs_ggs gs_fl"?><a href="?([^\s"]+)?"?[^>]+?><span class="?gs_ctg2"?>\[PDF\]</span>', re.I)
self.citation_block = re.compile('<div class="?gs_fl"?>.*?</div>', re.I)
示例2: __init__
# 需要导入模块: from settings import Settings [as 别名]
# 或者: from settings.Settings import getInstance [as 别名]
def __init__(self):
self.settings = Settings.getInstance()
self.debug = self.settings.debug
self.htmlRetriever = HtmlRetriever.getInstance(self.settings.use_proxy)
示例3: __init__
# 需要导入模块: from settings import Settings [as 别名]
# 或者: from settings.Settings import getInstance [as 别名]
def __init__(self):
self.settings = Settings.getInstance()
self.debug = self.settings.debug