Partition.fromJson constructor

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

Implementation

factory Partition.fromJson(Map<String, dynamic> json) {
  return Partition(
    catalogId: json['CatalogId'] as String?,
    creationTime: timeStampFromJson(json['CreationTime']),
    databaseName: json['DatabaseName'] as String?,
    lastAccessTime: timeStampFromJson(json['LastAccessTime']),
    lastAnalyzedTime: timeStampFromJson(json['LastAnalyzedTime']),
    parameters: (json['Parameters'] as Map<String, dynamic>?)
        ?.map((k, e) => MapEntry(k, e as String)),
    storageDescriptor: json['StorageDescriptor'] != null
        ? StorageDescriptor.fromJson(
            json['StorageDescriptor'] as Map<String, dynamic>)
        : null,
    tableName: json['TableName'] as String?,
    values: (json['Values'] as List?)
        ?.whereNotNull()
        .map((e) => e as String)
        .toList(),
  );
}