ListDeviceEventsResponse.fromJson constructor

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

Implementation

factory ListDeviceEventsResponse.fromJson(Map<String, dynamic> json) {
  return ListDeviceEventsResponse(
    deviceEvents: (json['DeviceEvents'] as List?)
        ?.whereNotNull()
        .map((e) => DeviceEvent.fromJson(e as Map<String, dynamic>))
        .toList(),
    nextToken: json['NextToken'] as String?,
  );
}