def dumps(self):
        """
        Dump this instance as YAML.

        """
        with closing(StringIO()) as fileobj:
            self.dump(fileobj)
            return fileobj.getvalue()
Dump this instance as YAML.