Queue.fromJson constructor

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

Implementation

factory Queue.fromJson(Map<String, dynamic> json) {
  return Queue(
    name: json['name'] as String,
    arn: json['arn'] as String?,
    createdAt: timeStampFromJson(json['createdAt']),
    description: json['description'] as String?,
    lastUpdated: timeStampFromJson(json['lastUpdated']),
    pricingPlan: (json['pricingPlan'] as String?)?.toPricingPlan(),
    progressingJobsCount: json['progressingJobsCount'] as int?,
    reservationPlan: json['reservationPlan'] != null
        ? ReservationPlan.fromJson(
            json['reservationPlan'] as Map<String, dynamic>)
        : null,
    status: (json['status'] as String?)?.toQueueStatus(),
    submittedJobsCount: json['submittedJobsCount'] as int?,
    type: (json['type'] as String?)?.toType(),
  );
}