ContainerStateRunning.fromJson constructor

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

Creates a ContainerStateRunning from JSON data.

Implementation

factory ContainerStateRunning.fromJson(Map<String, dynamic> json) {
  final tempStartedAtJson = json['startedAt'];

  final DateTime? tempStartedAt =
      tempStartedAtJson != null ? DateTime.tryParse(tempStartedAtJson) : null;

  return ContainerStateRunning(
    startedAt: tempStartedAt,
  );
}