|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JPanel org.greenstone.gs3client.BrowseDisplay
public class BrowseDisplay
The Browse panel inside the Java-client's tab pane that's labelled "Browse". This panel contains a tree view for expanding classifiers and their documents. It also contains an area where the metadata is displayed, and a text area where the textual or image content of a selected documentNode is displayed.
Nested Class Summary | |
---|---|
class |
BrowseDisplay.ClassifierButton
Inner class (not static, as it needs access to outerclass' this object. |
static class |
BrowseDisplay.ClassifierData
Static inner class that represents the data in a <classifier> element - itself nested inside a list (<classifierList>) of them. |
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
javax.swing.JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
javax.swing.JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
java.awt.Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary | |
---|---|
protected javax.swing.JPanel |
browseBar
|
protected javax.swing.JLabel |
browseLabel
|
protected javax.swing.JPanel |
browsePanel
|
protected javax.swing.JTree |
browsingTree
|
protected BrowseDisplay.ClassifierButton[] |
classifierList
|
protected GS3JavaClient |
client
Access to the running instance of GS3JavaClient |
protected java.util.HashMap |
displayData
A HashMap to store the displayData for the Browse operation. |
protected javax.swing.JEditorPane |
htmlPane
|
(package private) static org.apache.log4j.Logger |
LOG
The Logger for this class |
protected javax.swing.JList |
metanames
|
protected javax.swing.JList |
metavalues
|
protected javax.swing.JPopupMenu |
popup
Context menu that pops up when users right click in the browse tree area |
protected javax.swing.JSplitPane |
splitViewPane
|
protected javax.swing.JSplitPane |
structureMetaView
|
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
BrowseDisplay(GS3JavaClient client)
Constructor that creates the Browse Panel and its internal GUI items. |
Method Summary | |
---|---|
void |
changeUIColour()
Changes the colour of the query form and its controls to the current colours set in class ColourCombo. |
void |
clear()
Clears the service-specific buttons in the browseBar and the service-specific display-data. |
void |
displayBrowseOptions(org.w3c.dom.Element describeRespMsgTag)
Will clear previous browse service's classification options and widgets, and redisplay browse options as specified by the describe Response Message XML returned from the browse Service. |
void |
displayBrowseResults(BrowseResponseData browseResponseObj,
java.lang.String rootName)
Called to populate the browsing tree with browse data. |
java.awt.Dimension |
getPreferredSize()
Overrode this method to resize the splitpanes within, upon resize. |
void |
paint(java.awt.Graphics g)
For some reason, the overriden getPreferredSize() is not called upon resize of this panel, so I am calling it manually whenever there's a call to paint this Panel. |
void |
treeWillCollapse(javax.swing.event.TreeExpansionEvent e)
Part of the TreeWillExpandListener interface. |
void |
treeWillExpand(javax.swing.event.TreeExpansionEvent e)
This method of the TreeWillExpandListener interface is called when the user clicked on an expandable node in the browsingTree. |
void |
valueChanged(javax.swing.event.TreeSelectionEvent e)
Whenever an item is clicked in the browsingTree, this method is called. |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
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, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isRequestFocusEnabled, isValidateRoot, 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 |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
static org.apache.log4j.Logger LOG
protected GS3JavaClient client
protected java.util.HashMap displayData
protected javax.swing.JLabel browseLabel
protected javax.swing.JPanel browsePanel
protected javax.swing.JSplitPane splitViewPane
protected javax.swing.JSplitPane structureMetaView
protected javax.swing.JPanel browseBar
protected BrowseDisplay.ClassifierButton[] classifierList
protected javax.swing.JTree browsingTree
protected javax.swing.JEditorPane htmlPane
protected javax.swing.JList metanames
protected javax.swing.JList metavalues
protected javax.swing.JPopupMenu popup
Constructor Detail |
---|
public BrowseDisplay(GS3JavaClient client)
client
- is the running instance of the client application through
which its methods can be accessed.Method Detail |
---|
public void clear()
public void changeUIColour()
changeUIColour
in interface ColourCombo.ColourChangeable
public void paint(java.awt.Graphics g)
paint
in class javax.swing.JComponent
g
- is the Graphics objectpublic java.awt.Dimension getPreferredSize()
getPreferredSize
in class javax.swing.JComponent
public void displayBrowseOptions(org.w3c.dom.Element describeRespMsgTag)
describeRespMsgTag
- - the (Classifier)Browse Service's describe
response message element, used to reset the classifier buttons in the
browseBar of this panel.public void displayBrowseResults(BrowseResponseData browseResponseObj, java.lang.String rootName)
browseResponseObj
- - stores the data of the response XML
message returned by the (Classifier)Browse service.rootName
- - the title/name of the root classifierpublic void treeWillExpand(javax.swing.event.TreeExpansionEvent e)
treeWillExpand
in interface javax.swing.event.TreeWillExpandListener
public void treeWillCollapse(javax.swing.event.TreeExpansionEvent e)
treeWillCollapse
in interface javax.swing.event.TreeWillExpandListener
public void valueChanged(javax.swing.event.TreeSelectionEvent e)
valueChanged
in interface javax.swing.event.TreeSelectionListener
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |