Venice 0.7beta

org.mov.chart.graph
Interface GraphUI

All Known Implementing Classes:
CountbackLineGraphUI, CustomGraphUI, ExpMovingAverageGraphUI, MACDGraphUI, PeriodGraphUI, PointAndFigureGraphUI, RSIGraphUI

public interface GraphUI

Defines a user interface for a graph. Graphs often have user-definable settings, such as the period of a moving average graph. Since there are many types of graphs it makes sense standardising how the user-definable settings are handled and how the user interface is displayed to the user. Therefore each graph may have an associated user interface which lets the user modify the graph's settings.

Each implementation of this class is instantiated by the associated graph. Therefore this interface has no set constructor as the constructor can vary depending on the graph.

This user interface will be displayed by the GraphSettingsDialog.

Author:
Andrew Leppard
See Also:
AbstractGraph, Graph, GraphSettingsDialog, GraphSource

Method Summary
 java.lang.String checkSettings()
          Check the current settings displayed in the user interface.
 javax.swing.JPanel getPanel()
          Return the user interface.
 java.util.HashMap getSettings()
          Return the current settings displayed in the user interface.
 void setSettings(java.util.HashMap settings)
          Display the given settings in the user interface.
 

Method Detail

getSettings

java.util.HashMap getSettings()
Return the current settings displayed in the user interface.

Returns:
current settings

checkSettings

java.lang.String checkSettings()
Check the current settings displayed in the user interface. Return an error message if the settings are invalid.

Returns:
the error message or null if the settings are valid

setSettings

void setSettings(java.util.HashMap settings)
Display the given settings in the user interface.

Parameters:
settings - the new settings

getPanel

javax.swing.JPanel getPanel()
Return the user interface.

Returns:
the user interface

Venice 0.7beta