tryReadBool method
Tries to read a boolean value from the source. If the value is not a
boolean, it returns null
.
Implementation
bool? tryReadBool(source, key) {
var value = readValue(source, key);
return isBool(value) ? value as bool : null;
}