|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectFairness.Graphing.Graph
public class Graph
Graph represents a graphical plot of 1 to 4 data series. A graph is created and customized entirely through its constructor, then the image for the graph can be written to a file.
Constructor Summary | |
---|---|
Graph(java.lang.String title,
java.lang.String leftLabel,
java.lang.String bottomLabel,
java.util.List<? extends NamedXYSeries> data,
GraphBounds bounds)
Constructs a new customized Graph. |
Method Summary | |
---|---|
edu.rit.swing.Displayable |
getDisplayable()
Returns the Displayable graph object so that the Graph can be used in alternate rendering contexts. |
void |
writeColorPng(java.io.File outputFile)
Writes to the given file a color PNG image of the graph. |
void |
writePostscript(java.io.File outputFile)
Writes to the given file a postscript image of the graph. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Graph(java.lang.String title, java.lang.String leftLabel, java.lang.String bottomLabel, java.util.List<? extends NamedXYSeries> data, GraphBounds bounds)
title
- non-null String with graph titleleftLabel
- non-null String with y axis labelbottomLabel
- non-null String with x axis labeldata
- non-null List of 1 to 4 NamedXYSeriesbounds
- non-null GraphBoundsMethod Detail |
---|
public edu.rit.swing.Displayable getDisplayable()
public void writeColorPng(java.io.File outputFile) throws java.io.IOException
outputFile
- non-null location of file to write
java.io.IOException
- if an error occurs trying to write the filepublic void writePostscript(java.io.File outputFile) throws java.io.IOException
outputFile
- non-null location of file to write
java.io.IOException
- if an error occurs trying to write the file
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |