copyWith method
TaskStatusNotificationParams
copyWith({
- NotificationMetaObject? meta,
- String? createdAt,
- String? lastUpdatedAt,
- int? pollInterval,
- TaskStatus? status,
- String? statusMessage,
- String? taskId,
- Object? ttl = absent,
- Object? ttlMs = absent,
- int? pollIntervalMs,
- Map<
String, InputRequest> ? inputRequests, - Map<
String, Object?> ? result, - ErrorObject? error,
A copy with the given properties replaced; everything else, unknown keys included, is kept.
Implementation
TaskStatusNotificationParams copyWith({
NotificationMetaObject? meta,
String? createdAt,
String? lastUpdatedAt,
int? pollInterval,
TaskStatus? status,
String? statusMessage,
String? taskId,
Object? ttl = absent,
Object? ttlMs = absent,
int? pollIntervalMs,
Map<String, InputRequest>? inputRequests,
Map<String, Object?>? result,
ErrorObject? error,
}) =>
TaskStatusNotificationParams.fromJson({
...toJson(),
if (meta != null) '_meta': $encode(meta),
if (createdAt != null) 'createdAt': $encode(createdAt),
if (lastUpdatedAt != null) 'lastUpdatedAt': $encode(lastUpdatedAt),
if (pollInterval != null) 'pollInterval': $encode(pollInterval),
if (status != null) 'status': $encode(status),
if (statusMessage != null) 'statusMessage': $encode(statusMessage),
if (taskId != null) 'taskId': $encode(taskId),
if (!identical(ttl, absent)) 'ttl': $encode(ttl),
if (!identical(ttlMs, absent)) 'ttlMs': $encode(ttlMs),
if (pollIntervalMs != null) 'pollIntervalMs': $encode(pollIntervalMs),
if (inputRequests != null) 'inputRequests': $encode(inputRequests),
if (result != null) 'result': $encode(result),
if (error != null) 'error': $encode(error),
});