RubricBasedInstructionFollowingInput.fromJson constructor

RubricBasedInstructionFollowingInput.fromJson(
  1. Object? j
)

Implementation

factory RubricBasedInstructionFollowingInput.fromJson(Object? j) {
  final json = j as Map<String, Object?>;
  return RubricBasedInstructionFollowingInput(
    metricSpec: switch (json['metricSpec']) {
      null => null,
      Object $1 => RubricBasedInstructionFollowingSpec.fromJson($1),
    },
    instance: switch (json['instance']) {
      null => null,
      Object $1 => RubricBasedInstructionFollowingInstance.fromJson($1),
    },
  );
}