swap_count_model.dart 649 B

123456789101112131415161718192021222324252627
  1. // ignore_for_file: non_constant_identifier_names
  2. class SwapCountModule {
  3. late int Total;
  4. late int Used;
  5. late int Available;
  6. SwapCountModule({
  7. required this.Total,
  8. required this.Used,
  9. required this.Available,
  10. });
  11. static Map<String, dynamic> toMap(SwapCountModule freeSwap) {
  12. var map = <String, dynamic>{};
  13. map['Total'] = freeSwap.Total;
  14. map['Used'] = freeSwap.Used;
  15. map['Available'] = freeSwap.Available;
  16. return map;
  17. }
  18. factory SwapCountModule.fromJson(dynamic json) {
  19. return SwapCountModule(
  20. Total: json['Total'],
  21. Used: json['Used'],
  22. Available: json['Available'],
  23. );
  24. }
  25. }