Java Doc for Line2D.java in  » 6.0-JDK-Core » AWT » java » awt » geom » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Home
Java Source Code / Java Documentation
1.6.0 JDK Core
2.6.0 JDK Modules
3.6.0 JDK Modules com.sun
4.6.0 JDK Modules com.sun.java
5.6.0 JDK Modules sun
6.6.0 JDK Platform
7.Ajax
8.Apache Harmony Java SE
9.Aspect oriented
10.Authentication Authorization
11.Blogger System
12.Build
13.Byte Code
14.Cache
15.Chart
16.Chat
17.Code Analyzer
18.Collaboration
19.Content Management System
20.Database Client
21.Database DBMS
22.Database JDBC Connection Pool
23.Database ORM
24.Development
25.EJB Server
26.ERP CRM Financial
27.ESB
28.Forum
29.Game
30.GIS
31.Graphic 3D
32.Graphic Library
33.Groupware
34.HTML Parser
35.IDE
36.IDE Eclipse
37.IDE Netbeans
38.Installer
39.Internationalization Localization
40.Inversion of Control
41.Issue Tracking
42.J2EE
43.J2ME
44.JBoss
45.JMS
46.JMX
47.Library
48.Mail Clients
49.Music
50.Net
51.Parser
52.PDF
53.Portal
54.Profiler
55.Project Management
56.Report
57.RSS RDF
58.Rule Engine
59.Science
60.Scripting
61.Search Engine
62.Security
63.Sevlet Container
64.Source Control
65.Swing Library
66.Template Engine
67.Test Coverage
68.Testing
69.UML
70.Web Crawler
71.Web Framework
72.Web Mail
73.Web Server
74.Web Services
75.Web Services apache cxf 2.2.6
76.Web Services AXIS2
77.Wiki Engine
78.Workflow Engines
79.XML
80.XML UI
Java Source Code / Java Documentation » 6.0 JDK Core » AWT » java.awt.geom 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   java.awt.geom.Line2D

Line2D
abstract public class Line2D implements Shape,Cloneable(Code)
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.37, 05/05/07
author:
   Jim Graham
since:
   1.2


Inner Class :public static class Float extends Line2D implements Serializable
Inner Class :public static class Double extends Line2D implements Serializable


Constructor Summary
protected  Line2D()
     This is an abstract class that cannot be instantiated directly.

Method Summary
public  Objectclone()
     Creates a new object of the same class as this object.
public  booleancontains(double x, double y)
     Tests if a specified coordinate is inside the boundary of this Line2D.
public  booleancontains(Point2D p)
     Tests if a given Point2D is inside the boundary of this Line2D.
public  booleancontains(double x, double y, double w, double h)
     Tests if the interior of this Line2D entirely contains the specified set of rectangular coordinates.
public  booleancontains(Rectangle2D r)
     Tests if the interior of this Line2D entirely contains the specified Rectangle2D.
public  RectanglegetBounds()
    
abstract public  Point2DgetP1()
     Returns the start Point2D of this Line2D.
abstract public  Point2DgetP2()
     Returns the end Point2D of this Line2D.
public  PathIteratorgetPathIterator(AffineTransform at)
     Returns an iteration object that defines the boundary of this Line2D.
public  PathIteratorgetPathIterator(AffineTransform at, double flatness)
     Returns an iteration object that defines the boundary of this flattened Line2D. The iterator for this class is not multi-threaded safe, which means that this Line2D class does not guarantee that modifications to the geometry of this Line2D object do not affect any iterations of that geometry that are already in process.
abstract public  doublegetX1()
     Returns the X coordinate of the start point in double precision.
abstract public  doublegetX2()
     Returns the X coordinate of the end point in double precision.
abstract public  doublegetY1()
     Returns the Y coordinate of the start point in double precision.
abstract public  doublegetY2()
     Returns the Y coordinate of the end point in double precision.
public  booleanintersects(double x, double y, double w, double h)
    
public  booleanintersects(Rectangle2D r)
    
public  booleanintersectsLine(double x1, double y1, double x2, double y2)
     Tests if the line segment from (x1,y1) to (x2,y2) intersects this line segment.
public  booleanintersectsLine(Line2D l)
     Tests if the specified line segment intersects this line segment.
public static  booleanlinesIntersect(double x1, double y1, double x2, double y2, double x3, double y3, double x4, double y4)
     Tests if the line segment from (x1,y1) to (x2,y2) intersects the line segment from (x3,y3) to (x4,y4) .
Parameters:
  x1 - the X coordinate of the start point of the firstspecified line segment
Parameters:
  y1 - the Y coordinate of the start point of the firstspecified line segment
Parameters:
  x2 - the X coordinate of the end point of the firstspecified line segment
Parameters:
  y2 - the Y coordinate of the end point of the firstspecified line segment
Parameters:
  x3 - the X coordinate of the start point of the secondspecified line segment
Parameters:
  y3 - the Y coordinate of the start point of the secondspecified line segment
Parameters:
  x4 - the X coordinate of the end point of the secondspecified line segment
Parameters:
  y4 - the Y coordinate of the end point of the secondspecified line segment true if the first specified line segment and the second specified line segment intersect each other; false otherwise.
public static  doubleptLineDist(double x1, double y1, double x2, double y2, double px, double py)
     Returns the distance from a point to a line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by the specified coordinates.
public  doubleptLineDist(double px, double py)
     Returns the distance from a point to this line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by this Line2D.
public  doubleptLineDist(Point2D pt)
     Returns the distance from a Point2D to this line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by this Line2D.
public static  doubleptLineDistSq(double x1, double y1, double x2, double y2, double px, double py)
     Returns the square of the distance from a point to a line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by the specified coordinates.
public  doubleptLineDistSq(double px, double py)
     Returns the square of the distance from a point to this line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by this Line2D.
public  doubleptLineDistSq(Point2D pt)
     Returns the square of the distance from a specified Point2D to this line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by this Line2D.
public static  doubleptSegDist(double x1, double y1, double x2, double y2, double px, double py)
     Returns the distance from a point to a line segment. The distance measured is the distance between the specified point and the closest point between the specified end points.
public  doubleptSegDist(double px, double py)
     Returns the distance from a point to this line segment. The distance measured is the distance between the specified point and the closest point between the current line's end points.
public  doubleptSegDist(Point2D pt)
     Returns the distance from a Point2D to this line segment. The distance measured is the distance between the specified point and the closest point between the current line's end points.
public static  doubleptSegDistSq(double x1, double y1, double x2, double y2, double px, double py)
     Returns the square of the distance from a point to a line segment. The distance measured is the distance between the specified point and the closest point between the specified end points.
public  doubleptSegDistSq(double px, double py)
     Returns the square of the distance from a point to this line segment. The distance measured is the distance between the specified point and the closest point between the current line's end points.
public  doubleptSegDistSq(Point2D pt)
     Returns the square of the distance from a Point2D to this line segment. The distance measured is the distance between the specified point and the closest point between the current line's end points.
public static  intrelativeCCW(double x1, double y1, double x2, double y2, double px, double py)
     Returns an indicator of where the specified point (px,py) lies with respect to the line segment from (x1,y1) to (x2,y2) . The return value can be either 1, -1, or 0 and indicates in which direction the specified line must pivot around its first end point, (x1,y1) , in order to point at the specified point (px,py) .

A return value of 1 indicates that the line segment must turn in the direction that takes the positive X axis towards the negative Y axis.

public  intrelativeCCW(double px, double py)
     Returns an indicator of where the specified point (px,py) lies with respect to this line segment.
public  intrelativeCCW(Point2D p)
     Returns an indicator of where the specified Point2D lies with respect to this line segment.
abstract public  voidsetLine(double x1, double y1, double x2, double y2)
     Sets the location of the end points of this Line2D to the specified double coordinates.
public  voidsetLine(Point2D p1, Point2D p2)
     Sets the location of the end points of this Line2D to the specified Point2D coordinates.
public  voidsetLine(Line2D l)
     Sets the location of the end points of this Line2D to the same as those end points of the specified Line2D.


Constructor Detail
Line2D
protected Line2D()(Code)
This is an abstract class that cannot be instantiated directly. Type-specific implementation subclasses are available for instantiation and provide a number of formats for storing the information necessary to satisfy the various accessory methods below.
See Also:   java.awt.geom.Line2D.Float
See Also:   java.awt.geom.Line2D.Double
since:
   1.2




Method Detail
clone
public Object clone()(Code)
Creates a new object of the same class as this object. a clone of this instance.
exception:
  OutOfMemoryError - if there is not enough memory.
See Also:   java.lang.Cloneable
since:
   1.2



contains
public boolean contains(double x, double y)(Code)
Tests if a specified coordinate is inside the boundary of this Line2D. This method is required to implement the Shape interface, but in the case of Line2D objects it always returns false since a line contains no area.
Parameters:
  x - the X coordinate of the specified point to be tested
Parameters:
  y - the Y coordinate of the specified point to be tested false because a Line2D containsno area.
since:
   1.2



contains
public boolean contains(Point2D p)(Code)
Tests if a given Point2D is inside the boundary of this Line2D. This method is required to implement the Shape interface, but in the case of Line2D objects it always returns false since a line contains no area.
Parameters:
  p - the specified Point2D to be tested false because a Line2D containsno area.
since:
   1.2



contains
public boolean contains(double x, double y, double w, double h)(Code)
Tests if the interior of this Line2D entirely contains the specified set of rectangular coordinates. This method is required to implement the Shape interface, but in the case of Line2D objects it always returns false since a line contains no area.
Parameters:
  x - the X coordinate of the upper-left corner of thespecified rectangular area
Parameters:
  y - the Y coordinate of the upper-left corner of thespecified rectangular area
Parameters:
  w - the width of the specified rectangular area
Parameters:
  h - the height of the specified rectangular area false because a Line2D containsno area.
since:
   1.2



contains
public boolean contains(Rectangle2D r)(Code)
Tests if the interior of this Line2D entirely contains the specified Rectangle2D. This method is required to implement the Shape interface, but in the case of Line2D objects it always returns false since a line contains no area.
Parameters:
  r - the specified Rectangle2D to be tested false because a Line2D containsno area.
since:
   1.2



getBounds
public Rectangle getBounds()(Code)

since:
   1.2



getP1
abstract public Point2D getP1()(Code)
Returns the start Point2D of this Line2D. the start Point2D of this Line2D.
since:
   1.2



getP2
abstract public Point2D getP2()(Code)
Returns the end Point2D of this Line2D. the end Point2D of this Line2D.
since:
   1.2



getPathIterator
public PathIterator getPathIterator(AffineTransform at)(Code)
Returns an iteration object that defines the boundary of this Line2D. The iterator for this class is not multi-threaded safe, which means that this Line2D class does not guarantee that modifications to the geometry of this Line2D object do not affect any iterations of that geometry that are already in process.
Parameters:
  at - the specified AffineTransform a PathIterator that defines the boundary of thisLine2D.
since:
   1.2



getPathIterator
public PathIterator getPathIterator(AffineTransform at, double flatness)(Code)
Returns an iteration object that defines the boundary of this flattened Line2D. The iterator for this class is not multi-threaded safe, which means that this Line2D class does not guarantee that modifications to the geometry of this Line2D object do not affect any iterations of that geometry that are already in process.
Parameters:
  at - the specified AffineTransform
Parameters:
  flatness - the maximum amount that the control points for a given curve can vary from colinear before a subdividedcurve is replaced by a straight line connecting theend points. Since a Line2D object is always flat, this parameter is ignored. a PathIterator that defines the boundary of theflattened Line2D
since:
   1.2



getX1
abstract public double getX1()(Code)
Returns the X coordinate of the start point in double precision. the X coordinate of the start point of this Line2D object.
since:
   1.2



getX2
abstract public double getX2()(Code)
Returns the X coordinate of the end point in double precision. the X coordinate of the end point of this Line2D object.
since:
   1.2



getY1
abstract public double getY1()(Code)
Returns the Y coordinate of the start point in double precision. the Y coordinate of the start point of this Line2D object.
since:
   1.2



getY2
abstract public double getY2()(Code)
Returns the Y coordinate of the end point in double precision. the Y coordinate of the end point of this Line2D object.
since:
   1.2



intersects
public boolean intersects(double x, double y, double w, double h)(Code)

since:
   1.2



intersects
public boolean intersects(Rectangle2D r)(Code)

since:
   1.2



intersectsLine
public boolean intersectsLine(double x1, double y1, double x2, double y2)(Code)
Tests if the line segment from (x1,y1) to (x2,y2) intersects this line segment.
Parameters:
  x1 - the X coordinate of the start point of thespecified line segment
Parameters:
  y1 - the Y coordinate of the start point of thespecified line segment
Parameters:
  x2 - the X coordinate of the end point of thespecified line segment
Parameters:
  y2 - the Y coordinate of the end point of thespecified line segment if this line segment and the specified line segmentintersect each other; false otherwise.
since:
   1.2



intersectsLine
public boolean intersectsLine(Line2D l)(Code)
Tests if the specified line segment intersects this line segment.
Parameters:
  l - the specified Line2D true if this line segment and the specified linesegment intersect each other; false otherwise.
since:
   1.2



linesIntersect
public static boolean linesIntersect(double x1, double y1, double x2, double y2, double x3, double y3, double x4, double y4)(Code)
Tests if the line segment from (x1,y1) to (x2,y2) intersects the line segment from (x3,y3) to (x4,y4) .
Parameters:
  x1 - the X coordinate of the start point of the firstspecified line segment
Parameters:
  y1 - the Y coordinate of the start point of the firstspecified line segment
Parameters:
  x2 - the X coordinate of the end point of the firstspecified line segment
Parameters:
  y2 - the Y coordinate of the end point of the firstspecified line segment
Parameters:
  x3 - the X coordinate of the start point of the secondspecified line segment
Parameters:
  y3 - the Y coordinate of the start point of the secondspecified line segment
Parameters:
  x4 - the X coordinate of the end point of the secondspecified line segment
Parameters:
  y4 - the Y coordinate of the end point of the secondspecified line segment true if the first specified line segment and the second specified line segment intersect each other; false otherwise.
since:
   1.2



ptLineDist
public static double ptLineDist(double x1, double y1, double x2, double y2, double px, double py)(Code)
Returns the distance from a point to a line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by the specified coordinates. If the specified point intersects the line, this method returns 0.0.
Parameters:
  x1 - the X coordinate of the start point of the specified line
Parameters:
  y1 - the Y coordinate of the start point of the specified line
Parameters:
  x2 - the X coordinate of the end point of the specified line
Parameters:
  y2 - the Y coordinate of the end point of the specified line
Parameters:
  px - the X coordinate of the specified point beingmeasured against the specified line
Parameters:
  py - the Y coordinate of the specified point beingmeasured against the specified line a double value that is the distance from the specifiedpoint to the specified line.
See Also:   Line2D.ptSegDist(double,double,double,double,double,double)
since:
   1.2



ptLineDist
public double ptLineDist(double px, double py)(Code)
Returns the distance from a point to this line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by this Line2D. If the specified point intersects the line, this method returns 0.0.
Parameters:
  px - the X coordinate of the specified point beingmeasured against this line
Parameters:
  py - the Y coordinate of the specified point beingmeasured against this line a double value that is the distance from a specified pointto the current line.
See Also:   Line2D.ptSegDist(double,double)
since:
   1.2



ptLineDist
public double ptLineDist(Point2D pt)(Code)
Returns the distance from a Point2D to this line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by this Line2D. If the specified point intersects the line, this method returns 0.0.
Parameters:
  pt - the specified Point2D being measured a double value that is the distance from a specified Point2D to the current line.
See Also:   Line2D.ptSegDist(Point2D)
since:
   1.2



ptLineDistSq
public static double ptLineDistSq(double x1, double y1, double x2, double y2, double px, double py)(Code)
Returns the square of the distance from a point to a line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by the specified coordinates. If the specified point intersects the line, this method returns 0.0.
Parameters:
  x1 - the X coordinate of the start point of the specified line
Parameters:
  y1 - the Y coordinate of the start point of the specified line
Parameters:
  x2 - the X coordinate of the end point of the specified line
Parameters:
  y2 - the Y coordinate of the end point of the specified line
Parameters:
  px - the X coordinate of the specified point beingmeasured against the specified line
Parameters:
  py - the Y coordinate of the specified point beingmeasured against the specified line a double value that is the square of the distance from thespecified point to the specified line.
See Also:   Line2D.ptSegDistSq(double,double,double,double,double,double)
since:
   1.2



ptLineDistSq
public double ptLineDistSq(double px, double py)(Code)
Returns the square of the distance from a point to this line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by this Line2D. If the specified point intersects the line, this method returns 0.0.
Parameters:
  px - the X coordinate of the specified point beingmeasured against this line
Parameters:
  py - the Y coordinate of the specified point beingmeasured against this line a double value that is the square of the distance from a specified point to the current line.
See Also:   Line2D.ptSegDistSq(double,double)
since:
   1.2



ptLineDistSq
public double ptLineDistSq(Point2D pt)(Code)
Returns the square of the distance from a specified Point2D to this line. The distance measured is the distance between the specified point and the closest point on the infinitely-extended line defined by this Line2D. If the specified point intersects the line, this method returns 0.0.
Parameters:
  pt - the specified Point2D being measuredagainst this line a double value that is the square of the distance from aspecified Point2D to the currentline.
See Also:   Line2D.ptSegDistSq(Point2D)
since:
   1.2



ptSegDist
public static double ptSegDist(double x1, double y1, double x2, double y2, double px, double py)(Code)
Returns the distance from a point to a line segment. The distance measured is the distance between the specified point and the closest point between the specified end points. If the specified point intersects the line segment in between the end points, this method returns 0.0.
Parameters:
  x1 - the X coordinate of the start point of thespecified line segment
Parameters:
  y1 - the Y coordinate of the start point of thespecified line segment
Parameters:
  x2 - the X coordinate of the end point of thespecified line segment
Parameters:
  y2 - the Y coordinate of the end point of thespecified line segment
Parameters:
  px - the X coordinate of the specified point beingmeasured against the specified line segment
Parameters:
  py - the Y coordinate of the specified point beingmeasured against the specified line segment a double value that is the distance from the specified pointto the specified line segment.
See Also:   Line2D.ptLineDist(double,double,double,double,double,double)
since:
   1.2



ptSegDist
public double ptSegDist(double px, double py)(Code)
Returns the distance from a point to this line segment. The distance measured is the distance between the specified point and the closest point between the current line's end points. If the specified point intersects the line segment in between the end points, this method returns 0.0.
Parameters:
  px - the X coordinate of the specified point beingmeasured against this line segment
Parameters:
  py - the Y coordinate of the specified point beingmeasured against this line segment a double value that is the distance from the specified point to the current line segment.
See Also:   Line2D.ptLineDist(double,double)
since:
   1.2



ptSegDist
public double ptSegDist(Point2D pt)(Code)
Returns the distance from a Point2D to this line segment. The distance measured is the distance between the specified point and the closest point between the current line's end points. If the specified point intersects the line segment in between the end points, this method returns 0.0.
Parameters:
  pt - the specified Point2D being measuredagainst this line segment a double value that is the distance from the specifiedPoint2D to the current linesegment.
See Also:   Line2D.ptLineDist(Point2D)
since:
   1.2



ptSegDistSq
public static double ptSegDistSq(double x1, double y1, double x2, double y2, double px, double py)(Code)
Returns the square of the distance from a point to a line segment. The distance measured is the distance between the specified point and the closest point between the specified end points. If the specified point intersects the line segment in between the end points, this method returns 0.0.
Parameters:
  x1 - the X coordinate of the start point of thespecified line segment
Parameters:
  y1 - the Y coordinate of the start point of thespecified line segment
Parameters:
  x2 - the X coordinate of the end point of thespecified line segment
Parameters:
  y2 - the Y coordinate of the end point of thespecified line segment
Parameters:
  px - the X coordinate of the specified point beingmeasured against the specified line segment
Parameters:
  py - the Y coordinate of the specified point beingmeasured against the specified line segment a double value that is the square of the distance from thespecified point to the specified line segment.
See Also:   Line2D.ptLineDistSq(double,double,double,double,double,double)
since:
   1.2



ptSegDistSq
public double ptSegDistSq(double px, double py)(Code)
Returns the square of the distance from a point to this line segment. The distance measured is the distance between the specified point and the closest point between the current line's end points. If the specified point intersects the line segment in between the end points, this method returns 0.0.
Parameters:
  px - the X coordinate of the specified point beingmeasured against this line segment
Parameters:
  py - the Y coordinate of the specified point beingmeasured against this line segment a double value that is the square of the distance from thespecified point to the current line segment.
See Also:   Line2D.ptLineDistSq(double,double)
since:
   1.2



ptSegDistSq
public double ptSegDistSq(Point2D pt)(Code)
Returns the square of the distance from a Point2D to this line segment. The distance measured is the distance between the specified point and the closest point between the current line's end points. If the specified point intersects the line segment in between the end points, this method returns 0.0.
Parameters:
  pt - the specified Point2D being measured againstthis line segment. a double value that is the square of the distance from thespecified Point2D to the current line segment.
See Also:   Line2D.ptLineDistSq(Point2D)
since:
   1.2



relativeCCW
public static int relativeCCW(double x1, double y1, double x2, double y2, double px, double py)(Code)
Returns an indicator of where the specified point (px,py) lies with respect to the line segment from (x1,y1) to (x2,y2) . The return value can be either 1, -1, or 0 and indicates in which direction the specified line must pivot around its first end point, (x1,y1) , in order to point at the specified point (px,py) .

A return value of 1 indicates that the line segment must turn in the direction that takes the positive X axis towards the negative Y axis. In the default coordinate system used by Java 2D, this direction is counterclockwise.

A return value of -1 indicates that the line segment must turn in the direction that takes the positive X axis towards the positive Y axis. In the default coordinate system, this direction is clockwise.

A return value of 0 indicates that the point lies exactly on the line segment. Note that an indicator value of 0 is rare and not useful for determining colinearity because of floating point rounding issues.

If the point is colinear with the line segment, but not between the end points, then the value will be -1 if the point lies "beyond (x1,y1) " or 1 if the point lies "beyond (x2,y2) ".
Parameters:
  x1 - the X coordinate of the start point of thespecified line segment
Parameters:
  y1 - the Y coordinate of the start point of thespecified line segment
Parameters:
  x2 - the X coordinate of the end point of thespecified line segment
Parameters:
  y2 - the Y coordinate of the end point of thespecified line segment
Parameters:
  px - the X coordinate of the specified point to becompared with the specified line segment
Parameters:
  py - the Y coordinate of the specified point to becompared with the specified line segment an integer that indicates the position of the third specifiedcoordinates with respect to the line segment formedby the first two specified coordinates.
since:
   1.2




relativeCCW
public int relativeCCW(double px, double py)(Code)
Returns an indicator of where the specified point (px,py) lies with respect to this line segment. See the method comments of Line2D.relativeCCW(double,double,double,double,double,double) to interpret the return value.
Parameters:
  px - the X coordinate of the specified pointto be compared with this Line2D
Parameters:
  py - the Y coordinate of the specified pointto be compared with this Line2D an integer that indicates the position of the specifiedcoordinates with respect to this Line2D
See Also:   Line2D.relativeCCW(double,double,double,double,double,double)
since:
   1.2



relativeCCW
public int relativeCCW(Point2D p)(Code)
Returns an indicator of where the specified Point2D lies with respect to this line segment. See the method comments of Line2D.relativeCCW(double,double,double,double,double,double) to interpret the return value.
Parameters:
  p - the specified Point2D to be compared with this Line2D an integer that indicates the position of the specifiedPoint2D with respect to this Line2D
See Also:   Line2D.relativeCCW(double,double,double,double,double,double)
since:
   1.2



setLine
abstract public void setLine(double x1, double y1, double x2, double y2)(Code)
Sets the location of the end points of this Line2D to the specified double coordinates.
Parameters:
  x1 - the X coordinate of the start point
Parameters:
  y1 - the Y coordinate of the start point
Parameters:
  x2 - the X coordinate of the end point
Parameters:
  y2 - the Y coordinate of the end point
since:
   1.2



setLine
public void setLine(Point2D p1, Point2D p2)(Code)
Sets the location of the end points of this Line2D to the specified Point2D coordinates.
Parameters:
  p1 - the start Point2D of the line segment
Parameters:
  p2 - the end Point2D of the line segment
since:
   1.2



setLine
public void setLine(Line2D l)(Code)
Sets the location of the end points of this Line2D to the same as those end points of the specified Line2D.
Parameters:
  l - the specified Line2D
since:
   1.2



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.