checkFlag static method
Returns true if AccessNode has x flag
side: mode
/ want
/ given
Implementation
static bool checkFlag(AccessMode val, String? side, int flag) {
side ??= 'mode';
var found = ['given', 'want', 'mode'].where((s) {
return s == side;
}).toList();
if (found.isNotEmpty) {
return ((val[side] & flag) != 0);
}
throw Exception('Invalid AccessMode component "' + side + '"');
}