WorkItemStatus.fromJson constructor
WorkItemStatus.fromJson(
- Map _json
Implementation
WorkItemStatus.fromJson(core.Map _json)
: this(
completed: _json.containsKey('completed')
? _json['completed'] as core.bool
: null,
counterUpdates: _json.containsKey('counterUpdates')
? (_json['counterUpdates'] as core.List)
.map((value) => CounterUpdate.fromJson(
value as core.Map<core.String, core.dynamic>))
.toList()
: null,
dynamicSourceSplit: _json.containsKey('dynamicSourceSplit')
? DynamicSourceSplit.fromJson(_json['dynamicSourceSplit']
as core.Map<core.String, core.dynamic>)
: null,
errors: _json.containsKey('errors')
? (_json['errors'] as core.List)
.map((value) => Status.fromJson(
value as core.Map<core.String, core.dynamic>))
.toList()
: null,
metricUpdates: _json.containsKey('metricUpdates')
? (_json['metricUpdates'] as core.List)
.map((value) => MetricUpdate.fromJson(
value as core.Map<core.String, core.dynamic>))
.toList()
: null,
progress: _json.containsKey('progress')
? ApproximateProgress.fromJson(
_json['progress'] as core.Map<core.String, core.dynamic>)
: null,
reportIndex: _json.containsKey('reportIndex')
? _json['reportIndex'] as core.String
: null,
reportedProgress: _json.containsKey('reportedProgress')
? ApproximateReportedProgress.fromJson(_json['reportedProgress']
as core.Map<core.String, core.dynamic>)
: null,
requestedLeaseDuration: _json.containsKey('requestedLeaseDuration')
? _json['requestedLeaseDuration'] as core.String
: null,
sourceFork: _json.containsKey('sourceFork')
? SourceFork.fromJson(
_json['sourceFork'] as core.Map<core.String, core.dynamic>)
: null,
sourceOperationResponse: _json.containsKey('sourceOperationResponse')
? SourceOperationResponse.fromJson(
_json['sourceOperationResponse']
as core.Map<core.String, core.dynamic>)
: null,
stopPosition: _json.containsKey('stopPosition')
? Position.fromJson(
_json['stopPosition'] as core.Map<core.String, core.dynamic>)
: null,
totalThrottlerWaitTimeSeconds: _json
.containsKey('totalThrottlerWaitTimeSeconds')
? (_json['totalThrottlerWaitTimeSeconds'] as core.num).toDouble()
: null,
workItemId: _json.containsKey('workItemId')
? _json['workItemId'] as core.String
: null,
);