ArrayValue.fromJson constructor

ArrayValue.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory ArrayValue.fromJson(Map<String, dynamic> json) {
  return ArrayValue(
    arrayValues: (json['arrayValues'] as List?)
        ?.whereNotNull()
        .map((e) => ArrayValue.fromJson(e as Map<String, dynamic>))
        .toList(),
    booleanValues: (json['booleanValues'] as List?)
        ?.whereNotNull()
        .map((e) => e as bool)
        .toList(),
    doubleValues: (json['doubleValues'] as List?)
        ?.whereNotNull()
        .map((e) => e as double)
        .toList(),
    longValues: (json['longValues'] as List?)
        ?.whereNotNull()
        .map((e) => e as int)
        .toList(),
    stringValues: (json['stringValues'] as List?)
        ?.whereNotNull()
        .map((e) => e as String)
        .toList(),
  );
}