def update_children_comments(self): """ Banana banana """ if self.comment is None: return for sym in self.get_children_symbols(): if isinstance(sym, ParameterSymbol): sym.comment = self.comment.params.get(sym.argname) elif isinstance(sym, FieldSymbol): param_comment = self.comment.params.get(sym.member_name) if param_comment and (not sym.comment or not sym.comment.description): sym.comment = param_comment elif isinstance(sym, EnumMemberSymbol): if not sym.comment or not sym.comment.description: sym.comment = self.comment.params.get(sym.unique_name) elif isinstance(sym, ReturnItemSymbol): tag = self.comment.tags.get('returns') sym.comment = comment_from_tag(tag) elif type(sym) == Symbol: sym.comment = self.comment.params.get(sym.display_name) if isinstance(sym, Symbol): sym.update_children_comments()
def translate_tags(self, comment, link_resolver, include_resolver): """Banana banana """ for tname in ('deprecated',): tag = comment.tags.get(tname) if tag is not None and tag.description: comment = comment_from_tag(tag) ast = self.comment_to_ast(comment, link_resolver, include_resolver) tag.description = self.ast_to_html(ast, link_resolver) or ''
def update_children_comments(self): """ Banana banana """ if self.comment is None: return for sym in self.get_children_symbols(): if type(sym) == ParameterSymbol: sym.comment = self.comment.params.get(sym.argname) elif type(sym) == FieldSymbol: if not sym.comment or not sym.comment.description: sym.comment = self.comment.params.get(sym.member_name) elif type(sym) == ReturnItemSymbol: tag = self.comment.tags.get('returns') sym.comment = comment_from_tag(tag) elif type(sym) == Symbol: sym.comment = self.comment.params.get(sym.display_name)