checkArgument static method
If expression does not evaluate to true throws an ArgumentError
using the given argument, name and message.
Implementation
static void checkArgument(
Object argument, bool expression, String name, String message) {
if (!expression) {
throw ArgumentError.value(argument, name, message);
}
}