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: GraphBar.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 GraphBar extends GraphElement { |
2 |
26 Feb 07 |
jari |
17 |
public final static int VERTICAL = 0; |
2 |
26 Feb 07 |
jari |
18 |
public final static int HORIZONTAL = 1; |
2 |
26 Feb 07 |
jari |
19 |
|
2 |
26 Feb 07 |
jari |
20 |
public final static int SOLID = 0; |
2 |
26 Feb 07 |
jari |
21 |
public final static int OUTLINE = 1; |
2 |
26 Feb 07 |
jari |
22 |
|
2 |
26 Feb 07 |
jari |
23 |
private double lower, upper, value; |
2 |
26 Feb 07 |
jari |
24 |
private Color color; |
2 |
26 Feb 07 |
jari |
25 |
private int orientation; |
2 |
26 Feb 07 |
jari |
26 |
private int style; |
2 |
26 Feb 07 |
jari |
27 |
|
2 |
26 Feb 07 |
jari |
28 |
public GraphBar(double lower, double upper, double value, Color color, int orientation, int style) { |
2 |
26 Feb 07 |
jari |
29 |
this.lower = lower; |
2 |
26 Feb 07 |
jari |
30 |
this.upper = upper; |
2 |
26 Feb 07 |
jari |
31 |
this.value = value; |
2 |
26 Feb 07 |
jari |
32 |
this.color = color; |
2 |
26 Feb 07 |
jari |
33 |
this.orientation = orientation; |
2 |
26 Feb 07 |
jari |
34 |
this.style = style; |
2 |
26 Feb 07 |
jari |
35 |
} |
2 |
26 Feb 07 |
jari |
36 |
|
2 |
26 Feb 07 |
jari |
37 |
public GraphBar(double lower, double upper, double value) { |
2 |
26 Feb 07 |
jari |
38 |
this.lower = lower; |
2 |
26 Feb 07 |
jari |
39 |
this.upper = upper; |
2 |
26 Feb 07 |
jari |
40 |
this.color = Color.black; |
2 |
26 Feb 07 |
jari |
41 |
this.orientation = GraphBar.VERTICAL; |
2 |
26 Feb 07 |
jari |
42 |
this.style = GraphBar.SOLID; |
2 |
26 Feb 07 |
jari |
43 |
} |
2 |
26 Feb 07 |
jari |
44 |
|
2 |
26 Feb 07 |
jari |
45 |
public void setLower(double lower) {this.lower = lower;} |
2 |
26 Feb 07 |
jari |
46 |
public double getLower() {return this.lower;} |
2 |
26 Feb 07 |
jari |
47 |
public void setUpper(double upper) {this.upper = upper;} |
2 |
26 Feb 07 |
jari |
48 |
public double getUpper() {return this.upper;} |
2 |
26 Feb 07 |
jari |
49 |
public void setValue(double value) {this.value = value;} |
2 |
26 Feb 07 |
jari |
50 |
public double getValue() {return this.value;} |
2 |
26 Feb 07 |
jari |
51 |
public void setColor(Color color) {this.color = color;} |
2 |
26 Feb 07 |
jari |
52 |
public Color getColor() {return this.color;} |
2 |
26 Feb 07 |
jari |
53 |
public void setOrientation(int range) {this.orientation = range;} |
2 |
26 Feb 07 |
jari |
54 |
public int getOrientation() {return this.orientation;} |
2 |
26 Feb 07 |
jari |
55 |
public void setStyle(int style) {this.style = style;} |
2 |
26 Feb 07 |
jari |
56 |
public int getStyle() {return this.style;} |
2 |
26 Feb 07 |
jari |
57 |
} |