StudyTimeConstraint.fromJson constructor

StudyTimeConstraint.fromJson(
  1. Object? j
)

Implementation

factory StudyTimeConstraint.fromJson(Object? j) {
  final json = j as Map<String, Object?>;
  return StudyTimeConstraint(
    maxDuration: switch (json['maxDuration']) {
      null => null,
      Object $1 => protobuf.Duration.fromJson($1),
    },
    endTime: switch (json['endTime']) {
      null => null,
      Object $1 => protobuf.Timestamp.fromJson($1),
    },
  );
}