Asset.fromJson constructor

Asset.fromJson(
  1. Map json_
)

Implementation

Asset.fromJson(core.Map json_)
    : this(
        assignedGroups: json_.containsKey('assignedGroups')
            ? (json_['assignedGroups'] as core.List)
                .map((value) => value as core.String)
                .toList()
            : null,
        attributes: json_.containsKey('attributes')
            ? (json_['attributes'] as core.Map<core.String, core.dynamic>)
                .map(
                (key, value) => core.MapEntry(
                  key,
                  value as core.String,
                ),
              )
            : null,
        createTime: json_.containsKey('createTime')
            ? json_['createTime'] as core.String
            : null,
        insightList: json_.containsKey('insightList')
            ? InsightList.fromJson(
                json_['insightList'] as core.Map<core.String, core.dynamic>)
            : null,
        labels: json_.containsKey('labels')
            ? (json_['labels'] as core.Map<core.String, core.dynamic>).map(
                (key, value) => core.MapEntry(
                  key,
                  value as core.String,
                ),
              )
            : null,
        machineDetails: json_.containsKey('machineDetails')
            ? MachineDetails.fromJson(json_['machineDetails']
                as core.Map<core.String, core.dynamic>)
            : null,
        name: json_.containsKey('name') ? json_['name'] as core.String : null,
        performanceData: json_.containsKey('performanceData')
            ? AssetPerformanceData.fromJson(json_['performanceData']
                as core.Map<core.String, core.dynamic>)
            : null,
        sources: json_.containsKey('sources')
            ? (json_['sources'] as core.List)
                .map((value) => value as core.String)
                .toList()
            : null,
        updateTime: json_.containsKey('updateTime')
            ? json_['updateTime'] as core.String
            : null,
      );