Area class

A unit of measurement representing a two-dimensional area.

Inheritance

Constructors

Area.fromAcres(Rational acres)
Creates an Area representing the specified number of acres.
factory
Area.fromHectares(Rational hectares)
Creates an Area representing the specified number of hectares.
factory
Area.fromSquareCentimeters(Rational squareCentimeters)
Creates an Area representing the specified number of squareCentimeters.
factory
Area.fromSquareDecameters(Rational squareDecameters)
Creates an Area representing the specified number of squareDecameters.
factory
Area.fromSquareDecimeters(Rational squareDecimeters)
Creates an Area representing the specified number of squareDecimeters.
factory
Area.fromSquareFeet(Rational squareFeet)
Creates an Area representing the specified number of squareFeet.
factory
Area.fromSquareGigameters(Rational squareGigameters)
Creates an Area representing the specified number of squareGigameters.
factory
Area.fromSquareInches(Rational squareInches)
Creates an Area representing the specified number of squareInches.
factory
Area.fromSquareKilometers(Rational squareKilometers)
Creates an Area representing the specified number of squareKilometers.
factory
Area.fromSquareMegameters(Rational squareMegameters)
Creates an Area representing the specified number of squareMegameters.
factory
Area.fromSquareMeters(Rational squareMeters)
Creates an Area representing the specified number of squareMeters.
factory
Area.fromSquareMicrometers(Rational squareMicrometers)
Creates an Area representing the specified number of squareMicrometers.
factory
Area.fromSquareMiles(Rational squareMiles)
Creates an Area representing the specified number of squareMiles.
factory
Area.fromSquareMillimeters(Rational squareMillimeters)
Creates an Area representing the specified number of squareMillimeters.
factory
Area.fromSquareNanometers(Rational squareNanometers)
Creates an Area representing the specified number of squareNanometers.
factory
Area.fromSquareThous(Rational squareThous)
Creates an Area representing the specified number of squareThous.
factory
Area.fromSquareYards(Rational squareYards)
Creates an Area representing the specified number of squareYards.
factory
Area.fromUnits(AreaUnit unit, Rational value)
Creates an Area given a unit and rational value for that unit.

Properties

acres → Rational
Gets the number of acres in this Area, including any fractional portion.
no setter
baseValue ↔ Rational
The underlying base value of the unit of measurement.
latefinalinherited
hashCode int
The hash code for this object.
no setterinherited
hectares → Rational
Gets the number of hectares in this Area, including any fractional portion.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
squareCentimeters → Rational
Gets the number of square centimeters in this Area, including any fractional portion.
no setter
squareDecameters → Rational
Gets the number of square decameters in this Area, including any fractional portion.
no setter
squareDecimeters → Rational
Gets the number of square decimeters in this Area, including any fractional portion.
no setter
squareFeet → Rational
Gets the number of square feet in this Area, including any fractional portion.
no setter
squareGigameters → Rational
Gets the number of square gigameters in this Area, including any fractional portion.
no setter
squareInches → Rational
Gets the number of square inches in this Area, including any fractional portion.
no setter
squareKilometers → Rational
Gets the number of square kilometers in this Area, including any fractional portion.
no setter
squareMegameters → Rational
Gets the number of square megameters in this Area, including any fractional portion.
no setter
squareMeters → Rational
Gets the number of square meters in this Area, including any fractional portion.
no setter
squareMicrometers → Rational
Gets the number of square micrometers in this Area, including any fractional portion.
no setter
squareMiles → Rational
Gets the number of square miles in this Area, including any fractional portion.
no setter
squareMillimeters → Rational
Gets the number of square millimeters in this Area, including any fractional portion.
no setter
squareNanometers → Rational
Gets the number of square nanometers in this Area, including any fractional portion.
no setter
squareThous → Rational
Gets the number of square thous in this Area, including any fractional portion.
no setter
squareYards → Rational
Gets the number of square yards in this Area, including any fractional portion.
no setter

Methods

abs() Area
Gets the absolute value.
inherited
compareTo(Area other) int
Compares this object to another object.
inherited
createValue(Rational baseValue) Area
Creates a unit of measurement value with the specified baseValue.
override
getBaseValue(AreaUnit unit, Rational value) → Rational
Gets the base value for a unit of measurement of unit and value.
override
getLargestUnit({required Set<AreaUnit> permissibleUnits}) AreaUnit
Determines the largest unit that has a value of at least 1.
inherited
getUnits(AreaUnit unit) → Rational
Gets the number of unit units in this unit of measurement.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
per(Duration period) AreaRate
Creates an AreaRate with the specified period from this value.
round(AreaUnit roundTo) Area
Rounds this unit of measurement such that the roundTo unit will be rounded towards the nearest integer.
inherited
toString() String
A string representation of this object.
override

Operators

operator *(Rational factor) Area
Multiplies this value by factor.
inherited
operator +(Area other) Area
Adds other onto this value.
inherited
operator -(Area other) Area
Subtracts other from this value.
inherited
operator /(Rational divisor) Area
Divides this value by divisor.
inherited
operator <(Area other) bool
Determines whether this value is less than other.
inherited
operator <=(Area other) bool
Determines whether this value is less than or equal to other.
inherited
operator ==(Object other) bool
Determines whether this unit of measurement value is equal to other.
inherited
operator >(Area other) bool
Determines whether this value is greater than other.
inherited
operator >=(Area other) bool
Determines whether this value is greater than or equal to other.
inherited
operator unary-() Area
Negates this value.
inherited

Static Properties

zero Area
An Area of size zero.
final