plan method
Plans the import of editedMarkdown.
Throws ImportVerificationException when the rewritten YAML does not decode to the planned document.
Implementation
ImportPlan plan(String editedMarkdown) {
final textRefusals = allowOtherEdits
? const <String>[]
: compareNeutralised(rendition, editedMarkdown);
final codec = SpecDocumentMarkdown(type.model, document);
final edited = codec.parse(editedMarkdown);
if (textRefusals.isNotEmpty) {
return ImportPlan._(
refusals: textRefusals,
rejections: edited.rejections,
);
}
return _Planner(this, codec.parse(rendition), edited).run();
}