Package jmri.jmrit.logix
Class WarrantTableAction
java.lang.Object
javax.swing.AbstractAction
jmri.jmrit.logix.WarrantTableAction
- All Implemented Interfaces:
ActionListener,Serializable,Cloneable,EventListener,Action
A WarrantAction contains the operating permissions and directives needed for
a train to proceed from an Origin to a Destination. WarrantTableAction
provides the menu for panels to List, Edit and Create Warrants. It launches
the appropriate frame for each action.
This file is part of JMRI.
This file is part of JMRI.
JMRI is free software; you can redistribute it and/or modify it under the terms of version 2 of the GNU General Public License as published by the Free Software Foundation. See the "COPYING" file for a copy of this license.
JMRI is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
- See Also:
-
Field Summary
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabledFields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON -
Method Summary
Modifier and TypeMethodDescriptionvoidValidation of paths within a block.protected voidprotected booleanprotected voidbooleanstatic WarrantTableActionprotected WarrantFrameprotected JMenuItemprotected voidprotected voidmakeWarrantFrame(Warrant startW, Warrant endW) makeWarrantMenu(boolean edit) voidmouseClickedOnBlock(OBlock block) booleanshowPathPortalErrors(JTextArea textArea) protected voidprotected voidwritetoLog(String text) Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
-
Method Details
-
getDefault
-
actionPerformed
-
makeWarrantMenu
- Parameters:
edit- true if portal errors should be shown in window created from menu item- Returns:
- a menu containing warrant actions
-
updateWarrantMenu
-
makeLogMenu
-
writetoLog
-
closeNXFrame
-
makeNXFrame
-
closeWarrantFrame
-
makeWarrantFrame
-
editWarrantFrame
-
mouseClickedOnBlock
-
getOpenFrame
-
errorCheck
-
checkPathPortals
Validation of paths within a block. Gathers messages in a text area that can be displayed after all are written.- Parameters:
b- the block to validate- Returns:
- error/warning message, if any
-
showPathPortalErrors
-