toMap method

Map toMap()

Conversion to Map

Implementation

Map toMap() {
  Map map = Map();
  if (id != null) map[MAP_ID] = id;
  if (sentAt != null) map[MAP_SENT_AT] = sentAt;
  if (status != null) map[MAP_STATUS] = status;
  if (sendingId != null) map[MAP_SENDING_ID] = sendingId;
  if (message != null) map[MAP_MESSAGE] = message;
  map[MAP_READ] = read;

  return map;
}