fromJson static method

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

Returns a new Run instance and imports its values from json if it's non-null, null if json is null.

Implementation

static Run? fromJson(Map<String, dynamic>? json) {
  if (json == null) {
    return null;
  }

  return Run(
    children: Run.listFromJson(json[r'children']),
    error: json[r'error'],
    name: json[r'name'],
    result: json[r'result'] == null
        ? null
        : Map<String, Object>.from(json[r'result']),
    state: json[r'state'],
  );
}