Packagecom.rubenswieringa.geom
Classpublic class InfiniteLine
SubclassesLine

Describes a line consisting of a slope (coefficient) and an intersection-point with either the x or y axis.



Public Properties
 PropertyDefined by
  horizontal : Boolean
Indicates whether or not this InfiniteLine instance is horizontal.
InfiniteLine
  vertical : Boolean
Indicates whether or not this InfiniteLine instance is vertical.
InfiniteLine
  xCoefficient : Number
Value with which the y-position of this InfiniteLine increases, relative to that with which the x-position increases.
InfiniteLine
  xIntersection : Number
The x-position of the coordinate where this InfiniteLine crosses the x-axis (and consequently the y-position will be equal to zero).
InfiniteLine
  yCoefficient : Number
Value with which the x-position of this InfiniteLine increases, relative to that with which the y-position increases.
InfiniteLine
  yIntersection : Number
The y-position of the coordinate where this InfiniteLine crosses the y-axis (and consequently the x-position will be equal to zero).
InfiniteLine
Public Methods
 MethodDefined by
  
InfiniteLine(xIntersection:Number = 0, xCoefficient:Number = 1)
Constructor.
InfiniteLine
  
clone():*
Returns a cloned instance of this InfiniteLine.
InfiniteLine
  
containsPoint(point:Point, round:Boolean = true):Boolean
Returns true if the provided Point is on this InfiniteLine.
InfiniteLine
  
createFromPoints(a:Point, b:Point):InfiniteLine
[static] Creates an InfiniteLine at the hand of two Points.
InfiniteLine
  
createFromX(xIntersection:Number, xCoefficient:Number):InfiniteLine
[static] Creates an InfiniteLine instance at the hand of an x-intersection and an x-coefficient.
InfiniteLine
  
createFromY(yIntersection:Number, yCoefficient:Number):InfiniteLine
[static] Creates an InfiniteLine instance at the hand of an y-intersection and an y-coefficient.
InfiniteLine
  
equals(line:InfiniteLine, round:Boolean = true):Boolean
Returns true if the intersection-points and coefficients of both InfiniteLine instances are equal.
InfiniteLine
  
getAngle():Number
Returns the angle of this InfiniteLine with the x-axis.
InfiniteLine
  
[static] Returns a Point instance that represents the coordinate at which two InfiniteLine instances intersect.
InfiniteLine
  
getPointByX(x:Number):Point
Return a Point on this InfiniteLine where the x-position equals the specified value.
InfiniteLine
  
getPointByY(y:Number):Point
Return a Point on this InfiniteLine where the y-position equals the specified value.
InfiniteLine
  
isParallelTo(line:InfiniteLine, round:Boolean = true):Boolean
Returns true if the provided InfiniteLine instance is parallel to this InfiniteLine.
InfiniteLine
  
syncToPoints(a:Point, b:Point):void
Synchronizes this InfiniteLine instance to contain two Points.
InfiniteLine
  
toString():String
The String representation of this InfiniteLine instance.
InfiniteLine
Property detail
horizontalproperty
horizontal:Boolean  [read-write]

Indicates whether or not this InfiniteLine instance is horizontal.

Implementation
    public function get horizontal():Boolean
    public function set horizontal(value:Boolean):void

See also

verticalproperty 
vertical:Boolean  [read-write]

Indicates whether or not this InfiniteLine instance is vertical.

Implementation
    public function get vertical():Boolean
    public function set vertical(value:Boolean):void

See also

xCoefficientproperty 
xCoefficient:Number  [read-write]

Value with which the y-position of this InfiniteLine increases, relative to that with which the x-position increases.

Implementation
    public function get xCoefficient():Number
    public function set xCoefficient(value:Number):void

See also

xIntersectionproperty 
xIntersection:Number  [read-write]

The x-position of the coordinate where this InfiniteLine crosses the x-axis (and consequently the y-position will be equal to zero).

Implementation
    public function get xIntersection():Number
    public function set xIntersection(value:Number):void

See also

yCoefficientproperty 
yCoefficient:Number  [read-write]

Value with which the x-position of this InfiniteLine increases, relative to that with which the y-position increases.

Implementation
    public function get yCoefficient():Number
    public function set yCoefficient(value:Number):void

See also

yIntersectionproperty 
yIntersection:Number  [read-write]

The y-position of the coordinate where this InfiniteLine crosses the y-axis (and consequently the x-position will be equal to zero).

Implementation
    public function get yIntersection():Number
    public function set yIntersection(value:Number):void

See also

Constructor detail
InfiniteLine()constructor
public function InfiniteLine(xIntersection:Number = 0, xCoefficient:Number = 1)

Constructor.

Parameters
xIntersection:Number (default = 0)
 
xCoefficient:Number (default = 1)

See also

Method detail
clone()method
public function clone():*

Returns a cloned instance of this InfiniteLine.

Returns
* — InfiniteLine
containsPoint()method 
public function containsPoint(point:Point, round:Boolean = true):Boolean

Returns true if the provided Point is on this InfiniteLine.

Parameters
point:Point — Point instance representing a coordinate.
 
round:Boolean (default = true) — Boolean indicating whether or not to round values before making equations.

Returns
Boolean

See also

createFromPoints()method 
public static function createFromPoints(a:Point, b:Point):InfiniteLine

Creates an InfiniteLine at the hand of two Points.

Parameters
a:Point — Point
 
b:Point — Point

Returns
InfiniteLine — InfiniteLine

See also

createFromX()method 
public static function createFromX(xIntersection:Number, xCoefficient:Number):InfiniteLine

Creates an InfiniteLine instance at the hand of an x-intersection and an x-coefficient. Note that this method is exactly the same as the class its constructor.

Parameters
xIntersection:Number — x-position of this InfiniteLine's intersection-point with the x-axis.
 
xCoefficient:Number — x-coefficient.

Returns
InfiniteLine — InfiniteLine

See also

createFromY()method 
public static function createFromY(yIntersection:Number, yCoefficient:Number):InfiniteLine

Creates an InfiniteLine instance at the hand of an y-intersection and an y-coefficient.

Parameters
yIntersection:Number — y-position of this InfiniteLine's intersection-point with the y-axis.
 
yCoefficient:Number — y-coefficient.

Returns
InfiniteLine — InfiniteLine

See also

equals()method 
public function equals(line:InfiniteLine, round:Boolean = true):Boolean

Returns true if the intersection-points and coefficients of both InfiniteLine instances are equal.

Parameters
line:InfiniteLine — InfiniteLine
 
round:Boolean (default = true) — Boolean indicating whether or not to round values before making equations.

Returns
Boolean — Boolean
getAngle()method 
public function getAngle():Number

Returns the angle of this InfiniteLine with the x-axis.

Returns
Number — Angle in radians.
getIntersection()method 
public static function getIntersection(line1:InfiniteLine, line2:InfiniteLine):Point

Returns a Point instance that represents the coordinate at which two InfiniteLine instances intersect. Many thanks to Arno van Oordt for taking the time to explain the concept of intersection to me, check out his blog at http://blog.justgreat.nl

Parameters
line1:InfiniteLine — InfiniteLine
 
line2:InfiniteLine — InfiniteLine

Returns
Point — A Point instance if intersections occurs, null of otherwise.
getPointByX()method 
public function getPointByX(x:Number):Point

Return a Point on this InfiniteLine where the x-position equals the specified value.

Parameters
x:Number

Returns
Point — Point

See also

getPointByY()method 
public function getPointByY(y:Number):Point

Return a Point on this InfiniteLine where the y-position equals the specified value.

Parameters
y:Number

Returns
Point — Point

See also

isParallelTo()method 
public function isParallelTo(line:InfiniteLine, round:Boolean = true):Boolean

Returns true if the provided InfiniteLine instance is parallel to this InfiniteLine.

Parameters
line:InfiniteLine — InfiniteLine
 
round:Boolean (default = true) — Boolean indicating whether or not to round values before making equations.

Returns
Boolean — Boolean
syncToPoints()method 
public function syncToPoints(a:Point, b:Point):void

Synchronizes this InfiniteLine instance to contain two Points.

Parameters
a:Point — First Point.
 
b:Point — Second Point.
toString()method 
public function toString():String

The String representation of this InfiniteLine instance.

Returns
String — String