stack_wallet/lib/models/exchange/response_objects/range.dart

43 lines
725 B
Dart
Raw Normal View History

2023-05-26 21:21:16 +00:00
/*
* This file is part of Stack Wallet.
*
* Copyright (c) 2023 Cypher Stack
* All Rights Reserved.
* The code is distributed under GPLv3 license, see LICENSE file for details.
* Generated by Cypher Stack on 2023-05-26
*
*/
2022-10-02 19:37:11 +00:00
import 'package:decimal/decimal.dart';
class Range {
final Decimal? min;
final Decimal? max;
Range({this.min, this.max});
Range copyWith({
Decimal? min,
Decimal? max,
}) {
return Range(
min: min ?? this.min,
max: max ?? this.max,
);
}
Map<String, dynamic> toMap() {
final map = {
"min": min?.toString(),
"max": max?.toString(),
};
return map;
}
@override
String toString() {
return "Range: ${toMap()}";
}
}