Job.fromJson constructor

Job.fromJson(
  1. Map json_
)

Implementation

Job.fromJson(core.Map json_)
    : this(
        done: json_.containsKey('done') ? json_['done'] as core.bool : null,
        driverControlFilesUri: json_.containsKey('driverControlFilesUri')
            ? json_['driverControlFilesUri'] as core.String
            : null,
        driverOutputResourceUri: json_.containsKey('driverOutputResourceUri')
            ? json_['driverOutputResourceUri'] as core.String
            : null,
        driverSchedulingConfig: json_.containsKey('driverSchedulingConfig')
            ? DriverSchedulingConfig.fromJson(json_['driverSchedulingConfig']
                as core.Map<core.String, core.dynamic>)
            : null,
        flinkJob: json_.containsKey('flinkJob')
            ? FlinkJob.fromJson(
                json_['flinkJob'] as core.Map<core.String, core.dynamic>)
            : null,
        hadoopJob: json_.containsKey('hadoopJob')
            ? HadoopJob.fromJson(
                json_['hadoopJob'] as core.Map<core.String, core.dynamic>)
            : null,
        hiveJob: json_.containsKey('hiveJob')
            ? HiveJob.fromJson(
                json_['hiveJob'] as core.Map<core.String, core.dynamic>)
            : null,
        jobUuid: json_.containsKey('jobUuid')
            ? json_['jobUuid'] as core.String
            : 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,
        pigJob: json_.containsKey('pigJob')
            ? PigJob.fromJson(
                json_['pigJob'] as core.Map<core.String, core.dynamic>)
            : null,
        placement: json_.containsKey('placement')
            ? JobPlacement.fromJson(
                json_['placement'] as core.Map<core.String, core.dynamic>)
            : null,
        prestoJob: json_.containsKey('prestoJob')
            ? PrestoJob.fromJson(
                json_['prestoJob'] as core.Map<core.String, core.dynamic>)
            : null,
        pysparkJob: json_.containsKey('pysparkJob')
            ? PySparkJob.fromJson(
                json_['pysparkJob'] as core.Map<core.String, core.dynamic>)
            : null,
        reference: json_.containsKey('reference')
            ? JobReference.fromJson(
                json_['reference'] as core.Map<core.String, core.dynamic>)
            : null,
        scheduling: json_.containsKey('scheduling')
            ? JobScheduling.fromJson(
                json_['scheduling'] as core.Map<core.String, core.dynamic>)
            : null,
        sparkJob: json_.containsKey('sparkJob')
            ? SparkJob.fromJson(
                json_['sparkJob'] as core.Map<core.String, core.dynamic>)
            : null,
        sparkRJob: json_.containsKey('sparkRJob')
            ? SparkRJob.fromJson(
                json_['sparkRJob'] as core.Map<core.String, core.dynamic>)
            : null,
        sparkSqlJob: json_.containsKey('sparkSqlJob')
            ? SparkSqlJob.fromJson(
                json_['sparkSqlJob'] as core.Map<core.String, core.dynamic>)
            : null,
        status: json_.containsKey('status')
            ? JobStatus.fromJson(
                json_['status'] as core.Map<core.String, core.dynamic>)
            : null,
        statusHistory: json_.containsKey('statusHistory')
            ? (json_['statusHistory'] as core.List)
                .map((value) => JobStatus.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        trinoJob: json_.containsKey('trinoJob')
            ? TrinoJob.fromJson(
                json_['trinoJob'] as core.Map<core.String, core.dynamic>)
            : null,
        yarnApplications: json_.containsKey('yarnApplications')
            ? (json_['yarnApplications'] as core.List)
                .map((value) => YarnApplication.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
      );