UnitOfMeasuresDto class

Available extensions
Annotations
  • @freezed

Constructors

UnitOfMeasuresDto.new({required String unit, required double numerator, required double denominator})
const
factory
UnitOfMeasuresDto.fromJson(Json json)
factory

Properties

copyWith → $UnitOfMeasuresDtoCopyWith<UnitOfMeasuresDto>
Create a copy of UnitOfMeasuresDto with the given fields replaced by the non-null parameter values.
no setterinherited
denominator double
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
numerator double
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
unit String
no setterinherited

Methods

convertQuantity({required UnitOfMeasuresDto newUnit, required double value, bool removeZeros = false}) double

Available on UnitOfMeasuresDto, provided by the ConvertToUnit extension

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Serializes this UnitOfMeasuresDto to a JSON map.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited