@CreoleResource(name="Gazetteer Editor", comment="Gazetteer viewer and editor.", helpURL="http://gate.ac.uk/userguide/sec:gazetteers:anniegazeditor", guiType=LARGE, mainViewer=true, resourceDisplayed="gate.creole.gazetteer.AbstractGazetteer") public class GazetteerEditor extends AbstractVisualResource implements GazetteerListener, ActionsPublisher
ANNIE Gazetteer
.
Main features: - left table with 5 columns (List name, Major, Minor, Language, AnnotationType) 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 - drop down list with .lst files in directory - text fields and buttons to add a list/entry - for the second table, a button to filter the list and another to add columns - 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
Modifier and Type | Class and Description |
---|---|
protected class |
GazetteerEditor.ClearSelectionAction |
protected class |
GazetteerEditor.CopySelectionAction |
protected class |
GazetteerEditor.DeleteSelectedGazetteerNodeAction |
protected class |
GazetteerEditor.DeleteSelectedLinearNodeAction |
protected class |
GazetteerEditor.FillDownSelectionAction |
protected class |
GazetteerEditor.ListTableModel |
protected class |
GazetteerEditor.PasteSelectionAction |
protected class |
GazetteerEditor.ReloadGazetteerListAction |
protected class |
GazetteerEditor.SaveAndReinitialiseGazetteerAction |
protected class |
GazetteerEditor.SaveAsGazetteerAction |
JPanel.AccessibleJPanel
JComponent.AccessibleJComponent
Container.AccessibleAWTContainer
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Modifier and Type | Field and Description |
---|---|
protected List<Action> |
actions |
protected JButton |
addColumnsButton |
protected JCheckBox |
caseInsensitiveCheckBox |
protected Collator |
collator |
protected XJTable |
definitionTable |
protected DefaultTableModel |
definitionTableModel |
protected Gazetteer |
gazetteer |
protected LinearDefinition |
linearDefinition
the linear definition being displayed
|
protected JLabel |
listCountLabel |
protected JTextField |
listEntryTextField |
protected XJTable |
listTable |
protected GazetteerEditor.ListTableModel |
listTableModel |
protected JButton |
newListButton |
protected JComboBox<String> |
newListComboBox |
protected JCheckBox |
onlyValueCheckBox |
protected JCheckBox |
regexCheckBox |
protected LinearNode |
selectedLinearNode
the linear node currently selected
|
features, handle
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor and Description |
---|
GazetteerEditor() |
Modifier and Type | Method and Description |
---|---|
List<Action> |
getActions()
Returns a list of Action objects.
|
Resource |
init()
Initialise this resource, and return it.
|
protected void |
initGUI() |
protected void |
initListeners() |
void |
processGazetteerEvent(GazetteerEvent e)
Called when a Gazetteer event has occured
|
void |
setTarget(Object target)
Called by the GUI when this viewer/editor has to initialise itself for a
specific object.
|
cleanup, getFeatures, getInitParameterValues, getParameterValue, setFeatures, setHandle, setParameterValue, setParameterValues
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
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, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, 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
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, transferFocusDownCycle, validate, validateTree
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, 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, transferFocusBackward, transferFocusUpCycle
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getName, setName
protected LinearDefinition linearDefinition
protected LinearNode selectedLinearNode
protected XJTable definitionTable
protected DefaultTableModel definitionTableModel
protected GazetteerEditor.ListTableModel listTableModel
protected JComboBox<String> newListComboBox
protected JButton newListButton
protected JButton addColumnsButton
protected JTextField listEntryTextField
protected JCheckBox regexCheckBox
protected JCheckBox caseInsensitiveCheckBox
protected JCheckBox onlyValueCheckBox
protected JLabel listCountLabel
public GazetteerEditor()
public Resource init() throws ResourceInstantiationException
AbstractVisualResource
init
in interface Resource
init
in class AbstractVisualResource
ResourceInstantiationException
protected void initGUI()
protected void initListeners()
public void setTarget(Object target)
AbstractVisualResource
setTarget
in interface VisualResource
setTarget
in class AbstractVisualResource
target
- the object (be it a Resource
,
DataStore
or whatever) this viewer has to displaypublic void processGazetteerEvent(GazetteerEvent e)
GazetteerListener
processGazetteerEvent
in interface GazetteerListener
e
- Gazetteer Eventpublic List<Action> getActions()
ActionsPublisher
getActions
in interface ActionsPublisher
List
of Action
s.