code: def __str__(self):
      out = ""
  
      func, func_name = self.get_func()
  
      roles = {"func": "function", "meth": "method"}
  
      if self._role:
          if self._role not in roles:
              print("Warning: invalid role %s" % self._role)
          out += ".. {}:: {}\n    \n\n".format(
              roles.get(self._role, ""), func_name
          )
  
      out += super().__str__(func_role=self._role)
      return out
  
imports: import inspect
  import textwrap
  import re
  import pydoc
  from warnings import warn
  from collections import namedtuple
  from collections.abc import Callable, Mapping
  import copy
  import sys
label_desc: Use image node_id 3 for calling the FunctionDoc obj's underlying member method code with example usage: obj.__str__() and returns: out