toValue method

String toValue()

Implementation

String toValue() {
  switch (this) {
    case EmotionName.happy:
      return 'HAPPY';
    case EmotionName.sad:
      return 'SAD';
    case EmotionName.angry:
      return 'ANGRY';
    case EmotionName.confused:
      return 'CONFUSED';
    case EmotionName.disgusted:
      return 'DISGUSTED';
    case EmotionName.surprised:
      return 'SURPRISED';
    case EmotionName.calm:
      return 'CALM';
    case EmotionName.unknown:
      return 'UNKNOWN';
    case EmotionName.fear:
      return 'FEAR';
  }
}