matches method

bool matches(
  1. Entity entity
)

Implementation

bool matches(Entity entity) {
  if (any.isEmpty && all.isEmpty) {
    return true;
  }

  final anyMatched = matchesAny(entity);
  final allMatched = matchesAll(entity);

  return anyMatched && allMatched;
}