Ring class

A ring (annulus) defined by two concentric circles.

The ring is the region between innerRadius and outerRadius centered at center.

Constructors

Ring({required Point center, required double innerRadius, required double outerRadius})
Creates a ring with given center, innerRadius, and outerRadius.
const

Properties

area double
Area of the ring
no setter
averageRadius double
Average radius (midpoint between inner and outer)
no setter
center Point
Center point of the ring
final
hashCode int
The hash code for this object.
no setteroverride
innerCircumference double
Inner circumference
no setter
innerRadius double
Inner radius (hole)
final
outerCircumference double
Outer circumference
no setter
outerRadius double
Outer radius (boundary)
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
width double
Width of the ring (outer - inner)
no setter

Methods

contains(Point point) bool
Check if a point is inside the ring
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
scale(double factor) Ring
Scale the ring by factor
toString() String
A string representation of this object.
override
translate({double x = 0, double y = 0}) Ring
Translate the ring

Operators

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