toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  return <String, dynamic>{
    if (color != null) r'color': color,
    if (id != null) r'id': id,
    if (name != null) r'name': name,
    if (position != null) r'position': position,
    if (type != null) r'type': type,
  };
}