class_docstr: Assemble, save, and render DOT source code, open result in viewer.
class_docstr_tok: ["Assemble",",","save",",","and","render","DOT","source","code",",","open","result","in","viewer","."]
docstr: Reset content to an empty body, clear graph/node/egde_attr mappings.
  
  Args:
      keep_attrs (bool): preserve graph/node/egde_attr mappings
docstr_tok: ["Reset","content","to","an","empty","body",",","clear","graph\/node\/egde_attr","mappings",".","Args",":","keep_attrs","(","bool",")",":","preserve","graph\/node\/egde_attr","mappings"]
code: def clear(self, keep_attrs=False):
      """Reset content to an empty body, clear graph/node/egde_attr mappings.
  
      Args:
          keep_attrs (bool): preserve graph/node/egde_attr mappings
      """
      if not keep_attrs:
          for a in (self.graph_attr, self.node_attr, self.edge_attr):
              a.clear()
      del self.body[:]
  
imports: from .None import backend
  from .None import files
  from .None import lang
label_desc: Use image node_id 3 for calling the Dot obj's underlying member method code with example usage: obj.clear(keep_attrs) without return types