DirectionVector class

///////////////////////////////////////////////////////////////////////////// A helper class representing a directional vector between two points.

This is used for calculations involving dashed lines.

Constructors

DirectionVector.get(Offset firstVector, Offset secondVector)
factory
DirectionVector.nil(Offset offset)
factory

Properties

firstVector Offset
The startpoint of the vector
final
hashCode int
The hash code for this object.
no setterinherited
length double
the length of the vector
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
secondVector Offset
The endpoint of the vector
final
vector Offset
the relative width/height of the vector
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
reduce(double smallVectorLength) → (DirectionVector, double)
Returns a new vector starting after smallVectorLength and ending at secondVector Returns the remaining length of smallVectorLength if we cannot fully consume it
toString() String
A string representation of this object.
inherited

Operators

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