toInstanceType method
Implementation
InstanceType toInstanceType() {
switch (this) {
case 'Blue':
return InstanceType.blue;
case 'Green':
return InstanceType.green;
}
throw Exception('$this is not known in enum InstanceType');
}