2 |
26 Feb 07 |
jari |
1 |
/* |
2 |
26 Feb 07 |
jari |
Copyright @ 1999-2003, The Institute for Genomic Research (TIGR). |
2 |
26 Feb 07 |
jari |
All rights reserved. |
2 |
26 Feb 07 |
jari |
4 |
*/ |
2 |
26 Feb 07 |
jari |
5 |
/* |
2 |
26 Feb 07 |
jari |
* $RCSfile: GraphLine.java,v $ |
2 |
26 Feb 07 |
jari |
* $Revision: 1.4 $ |
2 |
26 Feb 07 |
jari |
* $Date: 2005/03/10 15:22:39 $ |
2 |
26 Feb 07 |
jari |
* $Author: braistedj $ |
2 |
26 Feb 07 |
jari |
* $State: Exp $ |
2 |
26 Feb 07 |
jari |
11 |
*/ |
2 |
26 Feb 07 |
jari |
12 |
package org.tigr.graph; |
2 |
26 Feb 07 |
jari |
13 |
|
2 |
26 Feb 07 |
jari |
14 |
import java.awt.Color; |
2 |
26 Feb 07 |
jari |
15 |
|
2 |
26 Feb 07 |
jari |
16 |
public class GraphLine extends GraphElement implements java.io.Serializable { |
2 |
26 Feb 07 |
jari |
17 |
public static final long serialVersionUID = 1000101020001L; |
2 |
26 Feb 07 |
jari |
18 |
private double x1, y1, x2, y2; |
2 |
26 Feb 07 |
jari |
19 |
private Color color; |
2 |
26 Feb 07 |
jari |
20 |
|
2 |
26 Feb 07 |
jari |
21 |
public GraphLine(double x1, double y1, double x2, double y2, Color color) { |
2 |
26 Feb 07 |
jari |
22 |
this.x1 = x1; |
2 |
26 Feb 07 |
jari |
23 |
this.y1 = y1; |
2 |
26 Feb 07 |
jari |
24 |
this.x2 = x2; |
2 |
26 Feb 07 |
jari |
25 |
this.y2 = y2; |
2 |
26 Feb 07 |
jari |
26 |
this.color = color; |
2 |
26 Feb 07 |
jari |
27 |
} |
2 |
26 Feb 07 |
jari |
28 |
|
2 |
26 Feb 07 |
jari |
29 |
public GraphLine(double x1, double y1, double x2, double y2) { |
2 |
26 Feb 07 |
jari |
30 |
this.x1 = x1; |
2 |
26 Feb 07 |
jari |
31 |
this.y1 = y1; |
2 |
26 Feb 07 |
jari |
32 |
this.x2 = x2; |
2 |
26 Feb 07 |
jari |
33 |
this.y2 = y2; |
2 |
26 Feb 07 |
jari |
34 |
this.color = Color.black; |
2 |
26 Feb 07 |
jari |
35 |
} |
2 |
26 Feb 07 |
jari |
36 |
|
2 |
26 Feb 07 |
jari |
37 |
public void setX1(double x1) {this.x1 = x1;} |
2 |
26 Feb 07 |
jari |
38 |
public double getX1() {return this.x1;} |
2 |
26 Feb 07 |
jari |
39 |
public void setX2(double x2) {this.x2 = x2;} |
2 |
26 Feb 07 |
jari |
40 |
public double getX2() {return this.x2;} |
2 |
26 Feb 07 |
jari |
41 |
public void setY1(double y1) {this.y1 = y1;} |
2 |
26 Feb 07 |
jari |
42 |
public double getY1() {return this.y1;} |
2 |
26 Feb 07 |
jari |
43 |
public void setY2(double y2) {this.y2 = y2;} |
2 |
26 Feb 07 |
jari |
44 |
public double getY2() {return this.y2;} |
2 |
26 Feb 07 |
jari |
45 |
public void setColor(Color color) {this.color = color;} |
2 |
26 Feb 07 |
jari |
46 |
public Color getColor() {return this.color;} |
2 |
26 Feb 07 |
jari |
47 |
} |