gate.gui
Class GazetteerEditor
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
gate.creole.AbstractVisualResource
gate.gui.GazetteerEditor
- All Implemented Interfaces:
- GazetteerListener, ActionsPublisher, Resource, FeatureBearer, NameBearer, VisualResource, ImageObserver, MenuContainer, Serializable, EventListener, Accessible
public class GazetteerEditor
- extends AbstractVisualResource
- implements GazetteerListener, ActionsPublisher
Editor for ANNIE Gazetteer.
Main features:
- left table with 4 columns (List name, Major, Minor, Language) for the
definition
- right table with 1+n columns (Value, Feature 1...Feature n) for the lists
- 'Save' on the context menu of the resources tree and tab
- context menu on both tables to delete selected rows
- list name drop down list with .lst files in directory and button [New List]
- value text field and button [New Entry]
- for the second table: [Add Cols]
- a text field case insensitive 'Filter' at the bottom of the right table
- both tables sorted case insensitively on the first column by default
- display in red the list name when the list is modified
- for the separator character test when editing feature columns
- make feature map ordered
- remove feature/value columns when containing only spaces or empty
- See Also:
- Serialized Form
| Methods inherited from class javax.swing.JComponent |
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
| Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree |
| Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
gazetteer
protected Gazetteer gazetteer
linearDefinition
protected LinearDefinition linearDefinition
- the linear definition being displayed
selectedLinearNode
protected LinearNode selectedLinearNode
- the linear node currently selected
collator
protected Collator collator
actions
protected List<Action> actions
definitionTable
protected XJTable definitionTable
definitionTableModel
protected DefaultTableModel definitionTableModel
listTable
protected XJTable listTable
listTableModel
protected GazetteerEditor.ListTableModel listTableModel
newListComboBox
protected JComboBox newListComboBox
newListButton
protected JButton newListButton
newEntryTextField
protected JTextField newEntryTextField
addColumnsButton
protected JButton addColumnsButton
listFilterTextField
protected JTextField listFilterTextField
regexCheckBox
protected JCheckBox regexCheckBox
caseInsensitiveCheckBox
protected JCheckBox caseInsensitiveCheckBox
onlyValueCheckBox
protected JCheckBox onlyValueCheckBox
listCountLabel
protected JLabel listCountLabel
GazetteerEditor
public GazetteerEditor()
init
public Resource init()
throws ResourceInstantiationException
- Description copied from class:
AbstractVisualResource
- Initialise this resource, and return it.
- Specified by:
init in interface Resource- Overrides:
init in class AbstractVisualResource
- Throws:
ResourceInstantiationException
initGUI
protected void initGUI()
initListeners
protected void initListeners()
setTarget
public void setTarget(Object target)
- Description copied from class:
AbstractVisualResource
- Called by the GUI when this viewer/editor has to initialise itself for a
specific object.
- Specified by:
setTarget in interface VisualResource- Overrides:
setTarget in class AbstractVisualResource
- Parameters:
target - the object (be it a Resource,
DataStore or whatever) this viewer has to display
processGazetteerEvent
public void processGazetteerEvent(GazetteerEvent e)
- Description copied from interface:
GazetteerListener
- Called when a Gazetteer event has occured
- Specified by:
processGazetteerEvent in interface GazetteerListener
- Parameters:
e - Gazetteer Event
getActions
public List getActions()
- Description copied from interface:
ActionsPublisher
- Returns a list of Action objects. This method will be called everytime a
menu for this resource needs to be built, thus allowing for dynamic updates
to the list of actions.
A null value in this list will cause a separator to be created.
- Specified by:
getActions in interface ActionsPublisher
- Returns:
- a
List of Actions.