inList static method

Validator inList(
  1. List<String> values, {
  2. String? message,
})

Ensures the value exactly matches one of the items in the provided list.

Implementation

static Validator inList(List<String> values, {String? message}) =>
    Validator._()..inList(values, message: message);