ContentEmbedding.fromJson constructor
ContentEmbedding.fromJson(
- Object? j
Implementation
factory ContentEmbedding.fromJson(Object? j) {
final json = j as Map<String, Object?>;
return ContentEmbedding(
values: switch (json['values']) {
null => [],
List<Object?> $1 => [for (final i in $1) decodeDouble(i)],
_ => throw const FormatException('"values" is not a list'),
},
);
}