encode method
- TeamColor self
override
Implementation
@override
dynamic encode(TeamColor self) {
switch (self) {
case TeamColor.pink:
return 'pink';
case TeamColor.red:
return 'red';
case TeamColor.orange:
return 'orange';
case TeamColor.yellow:
return 'yellow';
case TeamColor.green:
return 'green';
case TeamColor.blue:
return 'blue';
case TeamColor.indigo:
return 'indigo';
case TeamColor.purple:
return 'purple';
case TeamColor.brown:
return 'brown';
case TeamColor.white:
return 'white';
case TeamColor.black:
return 'black';
}
}