hep.wired.cut
Class CutEditor

java.lang.Object
  extended by hep.wired.cut.CutEditor
All Implemented Interfaces:
EventListener, ChangeListener

public class CutEditor
extends Object
implements ChangeListener

Class that maintains JTable of conditions in a Cut and controls that manipulate them.

Version:
$Id: $
Author:
Dmitry Onoprienko

Nested Class Summary
protected  class CutEditor.ConditionTableModel
          Model for a table of Cut's conditions.
 
Field Summary
protected  Action _actAdd
           
protected  Action _actDelete
           
protected  Action _actDeleteAll
           
protected  Action _actDeleteDisabled
           
protected  JButton _actions
           
protected  Action _actNew
           
protected  Action _actReset
           
protected  Action _actResetAll
           
protected  Action _actSync
           
protected  EnumMap<ConditionDefinition.Type,ConditionEditor> _conditionEditors
           
protected  ConditionEditor _currentEditor
           
protected  int _editRow
           
protected  boolean _enabled
           
protected  JCheckBox _hide
           
protected  CutManager _manager
           
protected  CutEditor.ConditionTableModel _model
           
protected  TableRowSorter<CutEditor.ConditionTableModel> _sorter
           
protected  JTable _table
           
protected  ListSelectionListener _tableSelectionListener
           
 
Constructor Summary
CutEditor()
           
 
Method Summary
 JButton getActionsButton()
           
 ConditionEditor getConditionEditor(ConditionDefinition.Type conditionType)
           
 JTable getConditionsTable()
           
 JCheckBox getHideDisabledBox()
           
 Condition getSelectedCondition()
          Returns currently selected condition.
static void main(String[] args)
           
 void setConditionEditor(ConditionDefinition.Type type, ConditionEditor editor)
           
 void setCut(Cut cut)
           
 void setEnabled(boolean state)
           
 void setManager(CutManager manager)
           
protected  void showConditionEditor(ConditionEditor editor)
           
 void stateChanged(ChangeEvent e)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_table

protected JTable _table

_model

protected CutEditor.ConditionTableModel _model

_sorter

protected TableRowSorter<CutEditor.ConditionTableModel> _sorter

_tableSelectionListener

protected ListSelectionListener _tableSelectionListener

_hide

protected JCheckBox _hide

_actions

protected JButton _actions

_actNew

protected Action _actNew

_actAdd

protected Action _actAdd

_actDelete

protected Action _actDelete

_actDeleteAll

protected Action _actDeleteAll

_actDeleteDisabled

protected Action _actDeleteDisabled

_actReset

protected Action _actReset

_actResetAll

protected Action _actResetAll

_actSync

protected Action _actSync

_conditionEditors

protected EnumMap<ConditionDefinition.Type,ConditionEditor> _conditionEditors

_currentEditor

protected ConditionEditor _currentEditor

_manager

protected CutManager _manager

_editRow

protected int _editRow

_enabled

protected boolean _enabled
Constructor Detail

CutEditor

public CutEditor()
Method Detail

setCut

public void setCut(Cut cut)

setManager

public void setManager(CutManager manager)

setConditionEditor

public void setConditionEditor(ConditionDefinition.Type type,
                               ConditionEditor editor)

setEnabled

public void setEnabled(boolean state)

getConditionsTable

public JTable getConditionsTable()

getActionsButton

public JButton getActionsButton()

getHideDisabledBox

public JCheckBox getHideDisabledBox()

getConditionEditor

public ConditionEditor getConditionEditor(ConditionDefinition.Type conditionType)

stateChanged

public void stateChanged(ChangeEvent e)
Specified by:
stateChanged in interface ChangeListener

getSelectedCondition

public Condition getSelectedCondition()
Returns currently selected condition. Returns null if no condition is selected.


showConditionEditor

protected void showConditionEditor(ConditionEditor editor)

main

public static void main(String[] args)


Copyright © 1996-2013 FreeHEP. All Rights Reserved.