public abstract class AbstractCalculation extends java.lang.Object implements Calculation
Modifier and Type | Field and Description |
---|---|
protected Control |
control |
protected java.text.DecimalFormat |
decimalFormat |
protected OSPFrame |
mainFrame |
Constructor and Description |
---|
AbstractCalculation() |
Modifier and Type | Method and Description |
---|---|
void |
addChildFrame(javax.swing.JFrame frame)
Adds a child frame that depends on the main frame.
|
abstract void |
calculate()
Does the calculation.
|
void |
clearChildFrames()
Clears the child frames from the main frame.
|
java.util.Collection |
getChildFrames()
Gets a copy of the ChildFrames collection.
|
static XML.ObjectLoader |
getLoader()
Returns an XML.ObjectLoader to save and load data for this object.
|
OSPFrame |
getMainFrame()
Gets the main OSPFrame.
|
OSPApplication |
getOSPApp()
Gets the main OSPFrame.
|
void |
reset()
Resets the program to its default state.
|
void |
resetCalculation()
Resets the calculation to a predefined state.
|
void |
setControl(Control control)
Sets object that controls this calculation.
|
protected OSPFrame mainFrame
protected Control control
protected java.text.DecimalFormat decimalFormat
public void setControl(Control control)
setControl
in interface Calculation
control
- public OSPFrame getMainFrame()
public void addChildFrame(javax.swing.JFrame frame)
frame
- JFramepublic OSPApplication getOSPApp()
public void clearChildFrames()
public java.util.Collection getChildFrames()
public abstract void calculate()
calculate
in interface Calculation
public void resetCalculation()
resetCalculation
in interface Calculation
public void reset()
public static XML.ObjectLoader getLoader()