toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final json = <String, dynamic>{};
  if (from != null) {
    json[r'from'] = from;
  }
  if (to != null) {
    json[r'to'] = to;
  }
  if (rank != null) {
    json[r'rank'] = rank;
  }
  if (type != null) {
    json[r'type'] = type;
  }
  if (strengthRange != null) {
    json[r'strengthRange'] = strengthRange;
  }
  if (substance != null) {
    json[r'substance'] = substance;
  }
  return json;
}