ProtoGoogleTimestamp.fromDynamic constructor

ProtoGoogleTimestamp.fromDynamic(
  1. Object? json
)

Parses either the field map or the canonical RFC 3339 string form.

Implementation

factory ProtoGoogleTimestamp.fromDynamic(Object? json) {
  if (json is String) return ProtoGoogleTimestamp.fromRfc3339(json);
  return ProtoGoogleTimestamp.fromJson((json as Map).cast<String, dynamic>());
}