(self, content, name)
| 23 | os.makedirs(directory) |
| 24 | |
| 25 | def _write_content(self, content, name): |
| 26 | |
| 27 | if isinstance(content, bytes): |
| 28 | with(open(name,'wb')) as fb: |
| 29 | fb.write(content) |
| 30 | else: |
| 31 | with(open(name,'w')) as fb: |
| 32 | fb.write(content) |
| 33 | |
| 34 | def save(self, content, format, name=None, directory:str=None) -> str: |
| 35 | output_directory = directory if directory is not None else self._output |