java::awt::geom::Line2D Class Reference

Inheritance diagram for java::awt::geom::Line2D:

Inheritance graph
java::lang::Object
[legend]
Collaboration diagram for java::awt::geom::Line2D:

Collaboration graph
java::lang::Object
[legend]

List of all members.


Detailed Description

This Line2D represents a line segment in (x, y) coordinate space.

This class, like all of the Java 2D API, uses a default coordinate system called user space in which the y-axis values increase downward and x-axis values increase to the right. For more information on the user space coordinate system, see the Coordinate Systems section of the Java 2D Programmer's Guide.

This class is only the abstract superclass for all objects that store a 2D line segment. The actual storage representation of the coordinates is left to the subclass.

Version:
1.27, 01/23/03
Author:
Jim Graham

Public Member Functions

virtual jdouble getX1 () const =0
 Returns the X coordinate of the start point in double precision.
virtual jdouble getY1 () const =0
 Returns the Y coordinate of the start point in double precision.
virtual jdouble getX2 () const =0
 Returns the X coordinate of the end point in double precision.
virtual jdouble getY2 () const =0
 Returns the Y coordinate of the end point in double precision.
virtual Ref< Point2DgetP1 () const =0
 Returns the starting Point2D of this Line2D.
virtual Ref< Point2DgetP2 () const =0
 Returns the end Point2D of this Line2D.
 Float (jfloat x1=0, jfloat y1=0, jfloat x2=0, jfloat y2=0)
 Constructs and initializes a Line from the specified coordinates.
 Float (const Point2D &p1, const Point2D &p2)
 Constructs and initializes a Line2D from the specified Point2D objects.
virtual jdouble getX1 () const
 Returns the Y coordinate of the start point in double precision.
virtual jdouble getY1 () const
 Returns the Y coordinate of the start point in double precision.
virtual jdouble getX2 () const
 Returns the X coordinate of the end point in double precision.
virtual jdouble getY2 () const
 Returns the Y coordinate of the end point in double precision.
virtual Ref< Point2DgetP1 () const
 Returns the starting Point2D of this Line2D.
virtual Ref< Point2DgetP2 () const
 Returns the end Point2D of this Line2D.
 Double (jdouble x1=0, jdouble y1=0, jdouble x2=0, jdouble y2=0)
 Constructs and initializes a Line2D from the specified coordinates.
 Double (const Point2D &p1, const Point2D &p2)
 Constructs and initializes a Line2D from the specified Point2D objects.
virtual jdouble getX1 () const
 Returns the X coordinate of the start point in double precision.
virtual jdouble getY1 () const
 Returns the Y coordinate of the start point in double precision.
virtual jdouble getX2 () const
 Returns the X coordinate of the end point in double precision.
virtual jdouble getY2 () const
 Returns the Y coordinate of the end point in double precision.
virtual Ref< Point2DgetP1 () const
 Returns the starting Point2D of this Line2D.
virtual Ref< Point2DgetP2 () const
 Returns the end Point2D of this Line2D.

Public Attributes

jfloat x1
 The X coordinate of the start point of the line segment.
jfloat y1
 The Y coordinate of the start point of the line segment.
jfloat x2
 The X coordinate of the end point of the line segment.
jfloat y2
 The Y coordinate of the end point of the line segment.
jdouble x1
 The X coordinate of the start point of the line segment.
jdouble y1
 The Y coordinate of the start point of the line segment.
jdouble x2
 The X coordinate of the end point of the line segment.
jdouble y2
 The Y coordinate of the end point of the line segment.

Member Function Documentation

virtual jdouble java::awt::geom::Line2D::getX1 (  )  const [pure virtual]

Returns the X coordinate of the start point in double precision.

Returns:
the X coordinate of this Line2D object's starting point.

virtual jdouble java::awt::geom::Line2D::getY1 (  )  const [pure virtual]

Returns the Y coordinate of the start point in double precision.

Returns:
the Y coordinate of this Line2D object's starting point.

virtual jdouble java::awt::geom::Line2D::getX2 (  )  const [pure virtual]

Returns the X coordinate of the end point in double precision.

Returns:
the X coordinate of this Line2D object's starting point.

virtual jdouble java::awt::geom::Line2D::getY2 (  )  const [pure virtual]

Returns the Y coordinate of the end point in double precision.

Returns:
the Y coordinate of this Line2D object's starting point.

virtual Ref<Point2D> java::awt::geom::Line2D::getP1 (  )  const [pure virtual]

Returns the starting Point2D of this Line2D.

Returns:
the starting Point2D of this Line2D

virtual Ref<Point2D> java::awt::geom::Line2D::getP2 (  )  const [pure virtual]

Returns the end Point2D of this Line2D.

Returns:
the ending Point2D of this Line2D.

java::awt::geom::Line2D::Float ( jfloat  x1 = 0,
jfloat  y1 = 0,
jfloat  x2 = 0,
jfloat  y2 = 0 
)

Constructs and initializes a Line from the specified coordinates.

Parameters:
X1,&nbsp;Y1 the first specified coordinates
X2,&nbsp;Y2 the second specified coordinates

java::awt::geom::Line2D::Float ( const Point2D p1,
const Point2D p2 
)

Constructs and initializes a Line2D from the specified Point2D objects.

Parameters:
p1,&nbsp;p2 the specified Point2D objects

virtual jdouble java::awt::geom::Line2D::getX1 (  )  const [virtual]

Returns the Y coordinate of the start point in double precision.

Returns:
the x coordinate of this Line2D object's starting point in double precision.

virtual jdouble java::awt::geom::Line2D::getY1 (  )  const [virtual]

Returns the Y coordinate of the start point in double precision.

Returns:
the x coordinate of this Line2D object's starting point in double precision.

virtual jdouble java::awt::geom::Line2D::getX2 (  )  const [virtual]

Returns the X coordinate of the end point in double precision.

Returns:
the x coordinate of this Line2D object's ending point in double precision.

virtual jdouble java::awt::geom::Line2D::getY2 (  )  const [virtual]

Returns the Y coordinate of the end point in double precision.

Returns:
the Y coordinate of this Line2D object's ending point in double precision.

virtual Ref<Point2D> java::awt::geom::Line2D::getP1 (  )  const [virtual]

Returns the starting Point2D of this Line2D.

Returns:
the starting Point2D of this Line2D

virtual Ref<Point2D> java::awt::geom::Line2D::getP2 (  )  const [virtual]

Returns the end Point2D of this Line2D.

Returns:
the ending Point2D of this Line2D.

java::awt::geom::Line2D::Double ( jdouble  x1 = 0,
jdouble  y1 = 0,
jdouble  x2 = 0,
jdouble  y2 = 0 
)

Constructs and initializes a Line2D from the specified coordinates.

Parameters:
X1,&nbsp;Y1 the first specified coordinate
X2,&nbsp;Y2 the second specified coordinate

java::awt::geom::Line2D::Double ( const Point2D p1,
const Point2D p2 
)

Constructs and initializes a Line2D from the specified Point2D objects.

Parameters:
p1,&nbsp;p2 the specified Point2D objects

virtual jdouble java::awt::geom::Line2D::getX1 (  )  const [virtual]

Returns the X coordinate of the start point in double precision.

Returns:
the X coordinate of this Line2D object's starting point.

virtual jdouble java::awt::geom::Line2D::getY1 (  )  const [virtual]

Returns the Y coordinate of the start point in double precision.

Returns:
the X coordinate of this Line2D object's starting point.

virtual jdouble java::awt::geom::Line2D::getX2 (  )  const [virtual]

Returns the X coordinate of the end point in double precision.

Returns:
the X coordinate of this Line2D object's starting point.

virtual jdouble java::awt::geom::Line2D::getY2 (  )  const [virtual]

Returns the Y coordinate of the end point in double precision.

Returns:
the X coordinate of this Line2D object's starting point.

virtual Ref<Point2D> java::awt::geom::Line2D::getP1 (  )  const [virtual]

Returns the starting Point2D of this Line2D.

Returns:
the starting Point2D of this Line2D

virtual Ref<Point2D> java::awt::geom::Line2D::getP2 (  )  const [virtual]

Returns the end Point2D of this Line2D.

Returns:
the ending Point2D of this Line2D.


Member Data Documentation

jfloat java::awt::geom::Line2D::x1

The X coordinate of the start point of the line segment.

jfloat java::awt::geom::Line2D::y1

The Y coordinate of the start point of the line segment.

jfloat java::awt::geom::Line2D::x2

The X coordinate of the end point of the line segment.

jfloat java::awt::geom::Line2D::y2

The Y coordinate of the end point of the line segment.

jdouble java::awt::geom::Line2D::x1

The X coordinate of the start point of the line segment.

jdouble java::awt::geom::Line2D::y1

The Y coordinate of the start point of the line segment.

jdouble java::awt::geom::Line2D::x2

The X coordinate of the end point of the line segment.

jdouble java::awt::geom::Line2D::y2

The Y coordinate of the end point of the line segment.


The documentation for this class was generated from the following file:
Generated on Fri May 16 11:56:21 2008 for CrossPlatformJavaLikeC++API by  doxygen 1.5.3