validate function

List<ValidationError> validate(
  1. Node node,
  2. Set<ValidationRule> rules
)

Validates a node given a Set of ValidationRules

Implementation

List<ValidationError> validate(
  ast.Node node,
  Set<ValidationRule> rules,
) {
  final validator = _Validator(
    rules: rules,
  );

  return validator.validate(
    node: node,
  );
}