hasAnyTagInPath method
searches the path for any tag specified in tags
and returns true, iff
one of the parent nodes contains at least one of these tags
Implementation
bool hasAnyTagInPath(List<String> tags) {
NodeV2? k = this;
while (k != null) {
if (tags.contains(k.startTagName)) return true;
k = k.parent;
}
return false;
}