Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
if self.decorators:
getDeprecated(self, list(self.decorators))
for x in super(TwistedFunction, self).docsources():
yield x
class TwistedASTBuilder(zopeinterface.ZopeInterfaceASTBuilder):
# Vistor is not a typo...
ModuleVistor = TwistedModuleVisitor
class TwistedSystem(zopeinterface.ZopeInterfaceSystem):
"""
A PyDoctor "system" used to generate the docs.
"""
defaultBuilder = TwistedASTBuilder
Function = TwistedFunction
def __init__(self, options=None):
super(TwistedSystem, self).__init__(options=options)
# Use custom SphinxInventory so that we can resolve valid L{} markup
# for which the Sphinx inventory is not published or broken.
self.intersphinx = TwistedSphinxInventory(
logger=self.msg, project_name=self.projectname)
def privacyClass(self, documentable):
"""
"""
Get are HEAD response for URL.
Here to help with testing and allow injecting another URL getter.
@param url: Full URL to the page which is retrieved.
@type url: L{str}
@return: The response for the HEAD method.
@rtype: urllib2 response
"""
return urllib2.urlopen(HeadRequest(url))
class TwistedSystem(zopeinterface.ZopeInterfaceSystem):
"""
Maybe class used to set up all pydoctor system.
"""
def __init__(self, options=None):
super(TwistedSystem, self).__init__(options=options)
# Use custom SphinxInventory so that we can resolve valid L{} markup
# for which the Sphinx inventory is not published or broken.
self.intersphinx = TwistedSphinxInventory(
logger=self.msg, project_name=self.projectname)
def privacyClass(self, documentable):
"""
Report the privacy level for an object.