Package jmri.jmrit.beantable
Class SectionTableAction
- java.lang.Object
-
- javax.swing.AbstractAction
-
- jmri.jmrit.beantable.AbstractTableAction<Section>
-
- jmri.jmrit.beantable.SectionTableAction
-
- All Implemented Interfaces:
java.awt.event.ActionListener
,java.io.Serializable
,java.lang.Cloneable
,java.util.EventListener
,javax.swing.Action
public class SectionTableAction extends AbstractTableAction<Section>
Swing action to create and register a SectionTable GUI.This file is part of JMRI.
JMRI is open source 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:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
SectionTableAction.BlockTableModel
Table model for Blocks in Create/Edit Section windowclass
SectionTableAction.EntryPointTableModel
Table model for Entry Points in Create/Edit Section window.-
Nested classes/interfaces inherited from class jmri.jmrit.beantable.AbstractTableAction
AbstractTableAction.TableItem<E extends NamedBean>
-
-
Field Summary
Fields Modifier and Type Field Description (package private) javax.swing.JCheckBox
_autoSystemName
(package private) javax.swing.JButton
addBlock
(package private) boolean
addCreateActive
(package private) JmriJFrame
addFrame
(package private) javax.swing.JRadioButton
automatic
(package private) Block
beginBlock
(package private) NamedBeanComboBox<Block>
blockBox
(package private) java.util.ArrayList<Block>
blockList
(package private) BlockManager
blockManager
(package private) javax.swing.JButton
create
(package private) LayoutEditor
curLayoutEditor
(package private) Section
curSection
(package private) javax.swing.JButton
deleteBlocks
(package private) boolean
editMode
(package private) Block
endBlock
(package private) java.util.ArrayList<EntryPoint>
entryPointList
(package private) javax.swing.ButtonGroup
entryPointOptions
(package private) SectionTableAction.EntryPointTableModel
entryPointTableModel
(package private) NamedBeanComboBox<Sensor>
forwardSensorBox
(package private) NamedBeanComboBox<Sensor>
forwardStopSensorBox
(package private) JmriJFrame
frame
(package private) Sensor
fSensor
(package private) Sensor
fStopSensor
(package private) javax.swing.JLabel
generationStateLabel
(package private) javax.swing.JComboBox<java.lang.String>
layoutEditorBox
(package private) java.util.ArrayList<LayoutEditor>
lePanelList
(package private) boolean
manualEntryPoints
(package private) javax.swing.JRadioButton
manually
(package private) UserPreferencesManager
pref
(package private) static java.util.ResourceBundle
rbx
(package private) NamedBeanComboBox<Sensor>
reverseSensorBox
(package private) NamedBeanComboBox<Sensor>
reverseStopSensorBox
(package private) Sensor
rSensor
(package private) Sensor
rStopSensor
(package private) SectionManager
sectionManager
(package private) javax.swing.JTextField
sysName
(package private) javax.swing.JLabel
sysNameFixed
(package private) javax.swing.JLabel
sysNameLabel
(package private) java.lang.String
systemNameAuto
(package private) javax.swing.JButton
update
(package private) javax.swing.JTextField
userName
(package private) javax.swing.JLabel
userNameLabel
-
Fields inherited from class jmri.jmrit.beantable.AbstractTableAction
f, includeAddButton, m
-
-
Constructor Summary
Constructors Constructor Description SectionTableAction()
SectionTableAction(java.lang.String actionName)
Create an action with a specific title.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) void
addBlockPressed(java.awt.event.ActionEvent e)
(package private) void
addEditPressed()
protected void
addPressed(java.awt.event.ActionEvent e)
Responds to the Add...button and the Edit buttons in the Section Table(package private) void
cancelPressed(java.awt.event.ActionEvent e)
protected void
createModel()
Create the JTable DataModel, along with the changes for the specific case of Section objects.(package private) void
createPressed(java.awt.event.ActionEvent e)
(package private) void
deleteBlocksPressed(java.awt.event.ActionEvent e)
(package private) void
editPressed(java.lang.String sName)
java.lang.String
getClassDescription()
protected java.lang.String
getClassName()
(package private) void
handleCreateException(java.lang.String sysName, java.lang.Exception ex)
protected java.lang.String
helpTarget()
Specify the JavaHelp target for this specific panel.void
setMenuBar(BeanTableFrame<Section> f)
Insert 2 table specific menus.protected void
setTitle()
Include the correct title.(package private) void
updatePressed(java.awt.event.ActionEvent e)
-
Methods inherited from class jmri.jmrit.beantable.AbstractTableAction
actionPerformed, addBottomButtons, addToFrame, addToFrame, addToPanel, columnsVisibleUpdated, configureManagerComboBox, configureTable, displayHwError, dispose, getFrame, getManager, getPanel, getTableDataModel, includeAddButton, nextName, print, removePrefixBoxListener, setFrame, setManager, setMessagePreferencesDetails
-
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
-
-
-
-
Field Detail
-
rbx
static final java.util.ResourceBundle rbx
-
entryPointTableModel
SectionTableAction.EntryPointTableModel entryPointTableModel
-
sectionManager
SectionManager sectionManager
-
blockManager
BlockManager blockManager
-
editMode
boolean editMode
-
curSection
Section curSection
-
addCreateActive
boolean addCreateActive
-
lePanelList
java.util.ArrayList<LayoutEditor> lePanelList
-
curLayoutEditor
LayoutEditor curLayoutEditor
-
beginBlock
Block beginBlock
-
fStopSensor
Sensor fStopSensor
-
rStopSensor
Sensor rStopSensor
-
entryPointList
java.util.ArrayList<EntryPoint> entryPointList
-
manualEntryPoints
boolean manualEntryPoints
-
addFrame
JmriJFrame addFrame
-
sysName
javax.swing.JTextField sysName
-
sysNameFixed
javax.swing.JLabel sysNameFixed
-
userName
javax.swing.JTextField userName
-
sysNameLabel
javax.swing.JLabel sysNameLabel
-
userNameLabel
javax.swing.JLabel userNameLabel
-
_autoSystemName
javax.swing.JCheckBox _autoSystemName
-
create
javax.swing.JButton create
-
update
javax.swing.JButton update
-
addBlock
javax.swing.JButton addBlock
-
deleteBlocks
javax.swing.JButton deleteBlocks
-
layoutEditorBox
javax.swing.JComboBox<java.lang.String> layoutEditorBox
-
blockBox
NamedBeanComboBox<Block> blockBox
-
forwardSensorBox
NamedBeanComboBox<Sensor> forwardSensorBox
-
reverseSensorBox
NamedBeanComboBox<Sensor> reverseSensorBox
-
forwardStopSensorBox
NamedBeanComboBox<Sensor> forwardStopSensorBox
-
reverseStopSensorBox
NamedBeanComboBox<Sensor> reverseStopSensorBox
-
manually
javax.swing.JRadioButton manually
-
automatic
javax.swing.JRadioButton automatic
-
entryPointOptions
javax.swing.ButtonGroup entryPointOptions
-
systemNameAuto
java.lang.String systemNameAuto
-
generationStateLabel
javax.swing.JLabel generationStateLabel
-
frame
JmriJFrame frame
-
-
Constructor Detail
-
SectionTableAction
public SectionTableAction(java.lang.String actionName)
Create an action with a specific title.Note that the argument is the Action title, not the title of the resulting frame. Perhaps this should be changed?
- Parameters:
actionName
- title of the action
-
SectionTableAction
public SectionTableAction()
-
-
Method Detail
-
createModel
protected void createModel()
Create the JTable DataModel, along with the changes for the specific case of Section objects.- Specified by:
createModel
in classAbstractTableAction<Section>
-
setTitle
protected void setTitle()
Description copied from class:AbstractTableAction
Include the correct title.- Specified by:
setTitle
in classAbstractTableAction<Section>
-
helpTarget
protected java.lang.String helpTarget()
Description copied from class:AbstractTableAction
Specify the JavaHelp target for this specific panel.- Overrides:
helpTarget
in classAbstractTableAction<Section>
- Returns:
- a fixed default string "index" pointing to to highest level in JMRI Help
-
addPressed
protected void addPressed(java.awt.event.ActionEvent e)
Responds to the Add...button and the Edit buttons in the Section Table- Specified by:
addPressed
in classAbstractTableAction<Section>
- Parameters:
e
- event which has triggered action
-
editPressed
void editPressed(java.lang.String sName)
-
addEditPressed
void addEditPressed()
-
createPressed
void createPressed(java.awt.event.ActionEvent e)
-
handleCreateException
void handleCreateException(java.lang.String sysName, java.lang.Exception ex)
-
cancelPressed
void cancelPressed(java.awt.event.ActionEvent e)
-
updatePressed
void updatePressed(java.awt.event.ActionEvent e)
-
deleteBlocksPressed
void deleteBlocksPressed(java.awt.event.ActionEvent e)
-
addBlockPressed
void addBlockPressed(java.awt.event.ActionEvent e)
-
setMenuBar
public void setMenuBar(BeanTableFrame<Section> f)
Insert 2 table specific menus. Account for the Window and Help menus, which are already added to the menu bar as part of the creation of the JFrame, by adding the menus 2 places earlier unless the table is part of the ListedTableFrame, that adds the Help menu later on.- Overrides:
setMenuBar
in classAbstractTableAction<Section>
- Parameters:
f
- the JFrame of this table
-
getClassName
protected java.lang.String getClassName()
- Specified by:
getClassName
in classAbstractTableAction<Section>
-
getClassDescription
public java.lang.String getClassDescription()
- Overrides:
getClassDescription
in classAbstractTableAction<Section>
-
-