Re: [Epydoc-devel] Setting DocChecker.PARAM for functions requires documentation of 'self'
Brought to you by:
edloper
|
From: <li...@ev...> - 2009-05-08 19:09:51
|
Solution:
class MyDocChecker(DocChecker, object):
"""
Subclass of epydoc's doc checker;
override function methods here.
"""
def _check_func(self, doc):
"""
Overrides the default epydoc checker's function checker.
Removes 'self' and 'cls' as arguments that need documentation.
@param doc: epydoc document object
@return: Whatever DocChecker._check_func() returns.
"""
try:
doc.posargs.remove(u'self')
except:
pass
try:
doc.posargs.remove(u'cls')
except:
pass
return super(MyDocChecker, self)._check_func(doc)
|