BaseBreakpoints<T> class

A set of breakpoints and associated values.

The smallest breakpoint must be 0. The value provided for the smallest breakpoint must not be null.

Extend this class to create custom breakpoint names and sizes.

Implementers

Constructors

BaseBreakpoints({required List<int> breakpoints, required List<T?> values, Map<int, T>? custom})
Creates a new set of breakpoints and associated values.

Properties

breakpoints List<int>
The integer widths at which layout changes will occur.
final
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
values List<T?>
The values used at each breakpoint.
final

Methods

choose(double width) → T
Chooses a value based on which of breakpoints is satisfied by width.
map<V>(V f(T?)) BaseBreakpoints<V>
Returns a new BaseBreakpoints with its values mapped to a new type.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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