Package adams.terminal.menu
Class FlowEditor
- java.lang.Object
-
- adams.terminal.menu.AbstractMenuItemDefinition
-
- adams.terminal.menu.FlowEditor
-
- All Implemented Interfaces:
MenuItem,Serializable,Comparable<AbstractMenuItemDefinition>
public class FlowEditor extends AbstractMenuItemDefinition
Lets the user select a flow, display it in raw format and save it again.- Version:
- $Revision$
- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class adams.terminal.menu.AbstractMenuItemDefinition
CATEGORY_HELP, CATEGORY_MAINTENANCE, CATEGORY_PROGRAM, CATEGORY_TOOLS, m_Owner
-
-
Constructor Summary
Constructors Constructor Description FlowEditor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddoRun(com.googlecode.lanterna.gui2.WindowBasedTextGUI context)Actual execution.StringgetCategory()Returns the category of the menu item in which it should appear, i.e., the name of the menu.StringgetTitle()Returns the title of the window (and text of menuitem).protected booleanisValid(String flow)Checks whether the flow is valid.-
Methods inherited from class adams.terminal.menu.AbstractMenuItemDefinition
compareTo, equals, getOwner, getRunnable, initialize, logError, logError, logMessage, postRun, preRun, setOwner
-
-
-
-
Method Detail
-
getTitle
public String getTitle()
Returns the title of the window (and text of menuitem).- Specified by:
getTitlein interfaceMenuItem- Specified by:
getTitlein classAbstractMenuItemDefinition- Returns:
- the title
-
isValid
protected boolean isValid(String flow)
Checks whether the flow is valid.- Parameters:
flow- the flow to check- Returns:
- true if valid
-
doRun
protected void doRun(com.googlecode.lanterna.gui2.WindowBasedTextGUI context)
Actual execution.- Specified by:
doRunin classAbstractMenuItemDefinition- Parameters:
context- the context to use
-
getCategory
public String getCategory()
Returns the category of the menu item in which it should appear, i.e., the name of the menu.- Specified by:
getCategoryin classAbstractMenuItemDefinition- Returns:
- the category/menu name
-
-