ScriptFailedToParseEvent.fromJson constructor
ScriptFailedToParseEvent.fromJson(
- Map<String, dynamic> json
)
Implementation
factory ScriptFailedToParseEvent.fromJson(Map<String, dynamic> json) {
return ScriptFailedToParseEvent(
scriptId: runtime.ScriptId.fromJson(json['scriptId'] as String),
url: json['url'] as String,
startLine: json['startLine'] as int,
startColumn: json['startColumn'] as int,
endLine: json['endLine'] as int,
endColumn: json['endColumn'] as int,
executionContextId: runtime.ExecutionContextId.fromJson(
json['executionContextId'] as int),
hash: json['hash'] as String,
executionContextAuxData: json.containsKey('executionContextAuxData')
? json['executionContextAuxData'] as Map<String, dynamic>
: null,
sourceMapURL: json.containsKey('sourceMapURL')
? json['sourceMapURL'] as String
: null,
hasSourceURL: json.containsKey('hasSourceURL')
? json['hasSourceURL'] as bool
: null,
isModule: json.containsKey('isModule') ? json['isModule'] as bool : null,
length: json.containsKey('length') ? json['length'] as int : null,
stackTrace: json.containsKey('stackTrace')
? runtime.StackTraceData.fromJson(
json['stackTrace'] as Map<String, dynamic>)
: null,
codeOffset:
json.containsKey('codeOffset') ? json['codeOffset'] as int : null,
scriptLanguage: json.containsKey('scriptLanguage')
? debugger.ScriptLanguage.fromJson(json['scriptLanguage'] as String)
: null,
embedderName: json.containsKey('embedderName')
? json['embedderName'] as String
: null,
);
}