PausedEvent.fromJson constructor

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

Implementation

factory PausedEvent.fromJson(Map<String, dynamic> json) {
  return PausedEvent(
    callFrames: (json['callFrames'] as List)
        .map((e) => CallFrame.fromJson(e as Map<String, dynamic>))
        .toList(),
    reason: PausedEventReason.fromJson(json['reason'] as String),
    data: json.containsKey('data')
        ? json['data'] as Map<String, dynamic>
        : null,
    hitBreakpoints: json.containsKey('hitBreakpoints')
        ? (json['hitBreakpoints'] as List).map((e) => e as String).toList()
        : null,
    asyncStackTrace: json.containsKey('asyncStackTrace')
        ? runtime.StackTraceData.fromJson(
            json['asyncStackTrace'] as Map<String, dynamic>)
        : null,
    asyncStackTraceId: json.containsKey('asyncStackTraceId')
        ? runtime.StackTraceId.fromJson(
            json['asyncStackTraceId'] as Map<String, dynamic>)
        : null,
  );
}