code: def dump_all(
      documents,
      stream=None,
      Dumper=Dumper,
      default_style=None,
      default_flow_style=False,
      canonical=None,
      indent=None,
      width=None,
      allow_unicode=None,
      line_break=None,
      encoding=None,
      explicit_start=None,
      explicit_end=None,
      version=None,
      tags=None,
      sort_keys=True,
  ):
      """
      Serialize a sequence of Python objects into a YAML stream.
      If stream is None, return the produced string instead.
      """
      getvalue = None
      if stream is None:
          if encoding is None:
              stream = io.StringIO()
          else:
              stream = io.BytesIO()
          getvalue = stream.getvalue
      dumper = Dumper(
          stream,
          default_style=default_style,
          default_flow_style=default_flow_style,
          canonical=canonical,
          indent=indent,
          width=width,
          allow_unicode=allow_unicode,
          line_break=line_break,
          encoding=encoding,
          version=version,
          tags=tags,
          explicit_start=explicit_start,
          explicit_end=explicit_end,
          sort_keys=sort_keys,
      )
      try:
          dumper.open()
          for data in documents:
              dumper.represent(data)
          dumper.close()
      finally:
          dumper.dispose()
      if getvalue:
          return getvalue()
  
imports: from .error import *
  from .tokens import *
  from .events import *
  from .nodes import *
  from .loader import *
  from .dumper import *
  import io
label_desc: Use image node_id 18 for calling a global function with example usage: dump_all(documents, stream, Dumper, default_style, default_flow_style, canonical, indent, width, allow_unicode, line_break, encoding, explicit_start, explicit_end, version, tags, sort_keys) and returns: getvalue