Message.fromJson constructor

Message.fromJson(
  1. Map json_
)

Implementation

Message.fromJson(core.Map json_)
    : this(
        historyId: json_['historyId'] as core.String?,
        id: json_['id'] as core.String?,
        internalDate: json_['internalDate'] as core.String?,
        labelIds: (json_['labelIds'] as core.List?)
            ?.map((value) => value as core.String)
            .toList(),
        payload: json_.containsKey('payload')
            ? MessagePart.fromJson(
                json_['payload'] as core.Map<core.String, core.dynamic>)
            : null,
        raw: json_['raw'] as core.String?,
        sizeEstimate: json_['sizeEstimate'] as core.int?,
        snippet: json_['snippet'] as core.String?,
        threadId: json_['threadId'] as core.String?,
      );