writeToFile method

Future writeToFile(
  1. File targetFile
)

Implementation

Future writeToFile(File targetFile) {
  final ioSink = targetFile.openWrite();
  try {
    YamlToString().writeYamlString(this.toJson(), ioSink);
  } catch (e) {
    throw DartBomException('$e', 5);
  } finally {
    return ioSink.close();
  }
}