RawPredictRequest.fromJson constructor

RawPredictRequest.fromJson(
  1. Object? j
)

Implementation

factory RawPredictRequest.fromJson(Object? j) {
  final json = j as Map<String, Object?>;
  return RawPredictRequest(
    endpoint: switch (json['endpoint']) {
      null => '',
      Object $1 => decodeString($1),
    },
    httpBody: switch (json['httpBody']) {
      null => null,
      Object $1 => HttpBody.fromJson($1),
    },
  );
}