|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--elge.engine.Graph
Graph is a data vizualizer object. It is used by an gui component to vizualize the data. This object is some sort of model for the gui object.
The graph has several properties that must be set before displaying it.
Constructor Summary | |
Graph()
Creates a new instance of Graph. |
|
Graph(Project pt)
Creates a new instance of Graph with a project |
Method Summary | |
void |
addProp(String prop)
adds a source to the graph |
protected com.jrefinery.data.CategoryDataset |
createCategoryData()
Creates data for graph from this graph setting. |
protected com.jrefinery.data.XYDataset |
createData()
Creates data for graph from this graph setting. |
protected com.jrefinery.data.XYDataset |
createFirstData()
Creates data for graph from this graph setting. |
protected com.jrefinery.chart.JFreeChart |
createJFreeChart()
Create the JFreeChart of a type and properties that defines this instance. |
protected com.jrefinery.data.XYDataset |
createOtherData()
Creates data for graph from this graph setting. |
protected com.jrefinery.data.PieDataset |
createPieCategoryData()
Creates data for graph from this graph setting. |
void |
dispose()
Disposes the graph. |
Project |
getProject()
gets the project that the graph is in. |
Vector |
getProps()
Get the sources |
String |
getTitle()
gets the graph title. |
int |
getType()
The type of the graph |
int |
getWindow()
Gets the window the graph is using (the tick step) |
String |
getXLabel()
gets the x axis label |
String |
getYLabel()
gets the y axis label |
void |
hide()
hides the graph view |
boolean |
isVisible()
check if it is displayed and visible. |
void |
removeProp(int idx)
removes a source from the graph |
void |
removeProp(String prop)
removes a source from the graph |
void |
repaint()
repaints the graph |
void |
restart()
restarts the graph. |
void |
setProject(Project pt)
sets the project for the graph. |
void |
setProps(Vector props)
Sets the graph source names |
void |
setTitle(String name)
Sets the graph title |
void |
setType(int type)
Sets the type of the graph |
void |
setWindow(int win)
Sets the tick step |
void |
setXLabel(String label)
gets the x axis label |
void |
setYLabel(String label)
gets the y axis label |
void |
show()
If the viewer was not created, it creates the graph and shows it. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Graph(Project pt)
pt
- the project the graph is in.public Graph()
Method Detail |
public Project getProject()
public void setProject(Project pt)
pt
- Project the graph is in.public String getTitle()
public void setTitle(String name)
name
- title of the graphpublic void setProps(Vector props)
props
- List of String objects, the source name..public Vector getProps()
public void addProp(String prop)
prop
- the source namepublic void removeProp(String prop)
prop
- the source namepublic void removeProp(int idx)
idx
- the source indexpublic int getType()
public void setType(int type)
type
- the graph type to setpublic int getWindow()
public void setWindow(int win)
win
- the tick step.public String getXLabel()
public void setXLabel(String label)
label
- name of x axispublic String getYLabel()
public void setYLabel(String label)
label
- name of x axispublic void dispose()
public boolean isVisible()
public void show()
protected com.jrefinery.data.XYDataset createData()
protected com.jrefinery.data.CategoryDataset createCategoryData()
protected com.jrefinery.data.PieDataset createPieCategoryData()
protected com.jrefinery.data.XYDataset createFirstData()
protected com.jrefinery.data.XYDataset createOtherData()
protected com.jrefinery.chart.JFreeChart createJFreeChart()
public void repaint()
public void hide()
public void restart()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |