RemoveExamplesRequest.fromJson constructor

RemoveExamplesRequest.fromJson(
  1. Object? j
)

Implementation

factory RemoveExamplesRequest.fromJson(Object? j) {
  final json = j as Map<String, Object?>;
  return RemoveExamplesRequest(
    storedContentsExampleFilter:
        switch (json['storedContentsExampleFilter']) {
          null => null,
          Object $1 => StoredContentsExampleFilter.fromJson($1),
        },
    exampleStore: switch (json['exampleStore']) {
      null => '',
      Object $1 => decodeString($1),
    },
    exampleIds: switch (json['exampleIds']) {
      null => [],
      List<Object?> $1 => [for (final i in $1) decodeString(i)],
      _ => throw const FormatException('"exampleIds" is not a list'),
    },
  );
}