PersistedQueryClient.fromJson constructor

PersistedQueryClient.fromJson(
  1. Map<String, Object?> json
)

Decodes a persisted snapshot from JSON-compatible data.

Implementation

factory PersistedQueryClient.fromJson(Map<String, Object?> json) =>
    PersistedQueryClient(
      timestamp: DateTime.fromMillisecondsSinceEpoch(
        json['timestamp']! as int,
      ),
      buster: json['buster']! as String,
      state: DehydratedState.fromJson(
        Map<String, Object?>.from(json['state']! as Map),
      ),
    );