convert method

  1. @override
String convert(
  1. Document input
)
override

Converts input and returns the result of the conversion.

Implementation

@override
String convert(Document input) {
  final buffer = StringBuffer();
  for (final node in input.root.children) {
    NodeParser? parser = parsers.firstWhereOrNull(
      (element) => element.id == node.type,
    );
    if (parser != null) {
      buffer.write(parser.transform(node, this));
    }
  }
  return buffer.toString();
}