Datastore.fromJson constructor

Datastore.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory Datastore.fromJson(Map<String, dynamic> json) {
  return Datastore(
    arn: json['arn'] as String?,
    creationTime: timeStampFromJson(json['creationTime']),
    fileFormatConfiguration: json['fileFormatConfiguration'] != null
        ? FileFormatConfiguration.fromJson(
            json['fileFormatConfiguration'] as Map<String, dynamic>)
        : null,
    lastMessageArrivalTime: timeStampFromJson(json['lastMessageArrivalTime']),
    lastUpdateTime: timeStampFromJson(json['lastUpdateTime']),
    name: json['name'] as String?,
    retentionPeriod: json['retentionPeriod'] != null
        ? RetentionPeriod.fromJson(
            json['retentionPeriod'] as Map<String, dynamic>)
        : null,
    status: (json['status'] as String?)?.toDatastoreStatus(),
    storage: json['storage'] != null
        ? DatastoreStorage.fromJson(json['storage'] as Map<String, dynamic>)
        : null,
  );
}