(self)
Grab signature (if given) and summary
Grab signature (if given) and summary
Grab signature ( if given ) and summary
def _parse_summary(self):
        """Grab signature (if given) and summary"""
        if self._is_at_section():
            return

        summary = self._doc.read_to_next_empty_line()
        summary_str = " ".join([s.strip() for s in summary]).strip()
        if re.compile('^([\w., ]+=)?\s*[\w\.]+\(.*\)$').match(summary_str):
            self['Signature'] = summary_str
            if not self._is_at_section():
                self['Summary'] = self._doc.read_to_next_empty_line()
        else:
            self['Summary'] = summary

        if not self._is_at_section():
            self['Extended Summary'] = self._read_to_next_section()
def _parse_summary ( self ) : if self . _is_at_section ( ) : return summary = self . _doc . read_to_next_empty_line ( ) summary_str = " " . join ( [ s . strip ( ) for s in summary ] ) . strip ( ) if re . compile ( '^([\w., ]+=)?\s*[\w\.]+\(.*\)$' ) . match ( summary_str ) : self [ 'Signature' ] = summary_str if not self . _is_at_section ( ) : self [ 'Summary' ] = self . _doc . read_to_next_empty_line ( ) else : self [ 'Summary' ] = summary if not self . _is_at_section ( ) : self [ 'Extended Summary' ] = self . _read_to_next_section ( )