ErrorContext.fromJson constructor

ErrorContext.fromJson(
  1. Map json_
)

Implementation

ErrorContext.fromJson(core.Map json_)
    : this(
        httpRequest: json_.containsKey('httpRequest')
            ? HttpRequestContext.fromJson(
                json_['httpRequest'] as core.Map<core.String, core.dynamic>)
            : null,
        reportLocation: json_.containsKey('reportLocation')
            ? SourceLocation.fromJson(json_['reportLocation']
                as core.Map<core.String, core.dynamic>)
            : null,
        sourceReferences: json_.containsKey('sourceReferences')
            ? (json_['sourceReferences'] as core.List)
                .map((value) => SourceReference.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        user: json_.containsKey('user') ? json_['user'] as core.String : null,
      );