toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final mode = this.mode;
  final value = this.value;
  return {
    if (mode != null) 'Mode': mode.toValue(),
    if (value != null) 'Value': value,
  };
}