updateWithLinkParams method
void
updateWithLinkParams({})
override
Updates content
, params and paramTypeMap
according to the new linked parameters
Implementation
@override
void updateWithLinkParams({
required Map<String, Set<String>> linkParamMap,
required Map<String, String> paramTypeMap,
}) {
_paramTypeMap.addAll(paramTypeMap);
_params.addAll(linkParamMap.values.expand((e) => e));
// build a temporary TextNode to get the updated content
final temp = RichTextNode(
path: path,
rawPath: rawPath,
modifiers: modifiers,
locale: locale,
types: types,
raw: raw,
comment: comment,
shouldEscape: shouldEscape,
handleTypes: handleTypes,
interpolation: interpolation,
paramCase: paramCase,
linkParamMap: linkParamMap,
);
_spans = temp.spans;
}