Package repast.simphony.ui
Class GUIParametersManager
- java.lang.Object
-
- repast.simphony.ui.GUIParametersManager
-
- All Implemented Interfaces:
ParameterSetter
public class GUIParametersManager extends Object implements ParameterSetter
Manages gui parameters such that parameters can be changed in the gui and then reset back to some set of default parameters.- Version:
- $Revision$ $Date$
- Author:
- Nick Collier
-
-
Constructor Summary
Constructors Constructor Description GUIParametersManager(Parameters params, ParametersUI pui)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
atEnd()
Returns false.Map<String,Double>
getDisplayOrder()
Gets GUI display order of the current parameters.Parameters
getParameters()
Gets the parameters object managed by this GUIParametersManager.void
next(Parameters params)
Sets the parameters to the next set of values.void
reset()
Resets the parameters managed by this GUIParametersManager back to their default values.void
reset(Parameters params)
Resets the parameters to the default values passed in on the constructor.void
saveParameters(File paramFile)
Saves the parameters in the specified file.
-
-
-
Constructor Detail
-
GUIParametersManager
public GUIParametersManager(Parameters params, ParametersUI pui)
-
-
Method Detail
-
atEnd
public boolean atEnd()
Returns false.- Specified by:
atEnd
in interfaceParameterSetter
- Returns:
- false
-
next
public void next(Parameters params)
Sets the parameters to the next set of values. In this case, that will be the values from the GUI.- Specified by:
next
in interfaceParameterSetter
- Parameters:
params
-
-
reset
public void reset(Parameters params)
Resets the parameters to the default values passed in on the constructor.- Specified by:
reset
in interfaceParameterSetter
- Parameters:
params
-
-
getDisplayOrder
public Map<String,Double> getDisplayOrder()
Gets GUI display order of the current parameters.- Returns:
- the order (a double) of the display parameters by display id.
-
reset
public void reset()
Resets the parameters managed by this GUIParametersManager back to their default values. The default values are whatever values the Parameters object held when it was passed in the constructor.
-
getParameters
public Parameters getParameters()
Gets the parameters object managed by this GUIParametersManager.- Returns:
- the parameters object managed by this GUIParametersManager.
-
saveParameters
public void saveParameters(File paramFile) throws IOException
Saves the parameters in the specified file.- Parameters:
paramFile
-- Throws:
IOException
- if there is an error saving the parameters to a file.
-
-