|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectbecker.xtras.grapher.GrapherGUI
public class GrapherGUI
GrapherGUI provides a user interface for graphing
mathematical functions when supplied with an instance of a student-written
class implementing one of the three interfaces IFunction,
IQuadraticFunction and IPolynomialFunction.
Please see the package description for a more in-depth discussion of using this class.
IFunction,
IQuadraticFunction,
IPolynomialFunction| Constructor Summary | |
|---|---|
GrapherGUI(IFunction f)
Construct a GUI for an object implementing the Function interface. |
|
GrapherGUI(IPolynomialFunction f)
Construct a GUI for an object implementing the PolynomialFunction interface. |
|
GrapherGUI(IQuadraticFunction f)
Construct a GUI for an object implementing the QuadraticFunction interface. |
|
| Method Summary | |
|---|---|
void |
setLocation(int x,
int y)
Set the location of the graphing window relative to the top-left corner of the screen. |
void |
setSize(int width,
int height)
Set the size of the graphing window. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public GrapherGUI(IFunction f)
Function interface.
f - the object with the function to be graphed.public GrapherGUI(IQuadraticFunction f)
QuadraticFunction interface.
f - the object with the function to be graphed.public GrapherGUI(IPolynomialFunction f)
PolynomialFunction interface.
f - the object with the function to be graphed.| Method Detail |
|---|
public void setSize(int width,
int height)
width - the width of the windowheight - the height of the window
public void setLocation(int x,
int y)
x - the x-coordinate of the new location's top-left cornery - the y-coordinate of the new location's top-left corner
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||