Range constructor

Range({
  1. Quantity? low,
  2. Quantity? high,
})

Constructs a new Range with an optional low and high limit.

Implementation

Range({
  Quantity? low,
  Quantity? high,
}) : this.fromJson(
        JsonObject({
          if (low != null) lowField.name: low.json,
          if (high != null) highField.name: high.json,
        }),
      );