Package hec.clientapp.model
Class ToolBarButtonManagerImpl
java.lang.Object
hec.clientapp.model.ToolBarButtonManagerImpl
- All Implemented Interfaces:
hec.appInterface.ToolBarButtonManager,PreferencesConstants
public class ToolBarButtonManagerImpl
extends Object
implements hec.appInterface.ToolBarButtonManager, PreferencesConstants
class for loading and saving customized ToolBarButtons
-
Field Summary
Fields inherited from interface hec.lang.PreferencesConstants
CWMS_ALL, CWMS_WATERSHED, NO_LOCATION, USER_ALL, USER_WATERSHED -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddToolBarButton(hec.appInterface.IToolBarButtonItem item) Add the toolBarItem to the current ApplicationModules toolbarbooleancontains(hec.appInterface.IToolBarButtonItem item) Check to see if the current ApplicationModule has toolBarItem already displayed in its toolbar.voidload()Loads the ToolbarItems from diskvoidload(BufferedReader reader) voidremoveToolBarButton(hec.appInterface.IToolBarButtonItem item) Remove the toolBarItem from the current ApplicationModules toolbar.voidreset the toolbar buttons to the default toolbar buttonsvoidsave()Save the contents of the ToolBarButtonManager to disk.voidsave(BufferedWriter writer)
-
Constructor Details
-
ToolBarButtonManagerImpl
public ToolBarButtonManagerImpl(hec.clientapp.client.ClientMode module)
-
-
Method Details
-
addToolBarButton
public void addToolBarButton(hec.appInterface.IToolBarButtonItem item) Description copied from interface:hec.appInterface.ToolBarButtonManagerAdd the toolBarItem to the current ApplicationModules toolbar- Specified by:
addToolBarButtonin interfacehec.appInterface.ToolBarButtonManager- Parameters:
item- The feature to be added to the ToolBarButton attribute
-
resetDefaultToolbars
public void resetDefaultToolbars()reset the toolbar buttons to the default toolbar buttons- Specified by:
resetDefaultToolbarsin interfacehec.appInterface.ToolBarButtonManager
-
removeToolBarButton
public void removeToolBarButton(hec.appInterface.IToolBarButtonItem item) Description copied from interface:hec.appInterface.ToolBarButtonManagerRemove the toolBarItem from the current ApplicationModules toolbar.- Specified by:
removeToolBarButtonin interfacehec.appInterface.ToolBarButtonManager- Parameters:
item- Description
-
contains
public boolean contains(hec.appInterface.IToolBarButtonItem item) Description copied from interface:hec.appInterface.ToolBarButtonManagerCheck to see if the current ApplicationModule has toolBarItem already displayed in its toolbar.- Specified by:
containsin interfacehec.appInterface.ToolBarButtonManager- Parameters:
item- Description- Returns:
- Description
-
save
public void save()Description copied from interface:hec.appInterface.ToolBarButtonManagerSave the contents of the ToolBarButtonManager to disk.- Specified by:
savein interfacehec.appInterface.ToolBarButtonManager
-
save
- Throws:
IOException
-
load
public void load()Description copied from interface:hec.appInterface.ToolBarButtonManagerLoads the ToolbarItems from disk- Specified by:
loadin interfacehec.appInterface.ToolBarButtonManager
-
load
-