ListViolationEventsResponse.fromJson constructor

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

Implementation

factory ListViolationEventsResponse.fromJson(Map<String, dynamic> json) {
  return ListViolationEventsResponse(
    nextToken: json['nextToken'] as String?,
    violationEvents: (json['violationEvents'] as List?)
        ?.whereNotNull()
        .map((e) => ViolationEvent.fromJson(e as Map<String, dynamic>))
        .toList(),
  );
}