elementMatchesAttributes function

bool elementMatchesAttributes(
  1. Element element,
  2. Map<String, dynamic> attributes
)

Returns true if element matches attributes.

Implementation

bool elementMatchesAttributes(
    Element element, Map<String, dynamic> attributes) {
  for (var entry in attributes.entries) {
    if (!elementMatchesAttribute(element, entry.key, entry.value)) {
      return false;
    }
  }
  return true;
}