uk.org.iscream.cms.conient
Class DataPanel
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--javax.swing.JComponent
|
+--javax.swing.JSplitPane
|
+--uk.org.iscream.cms.conient.DataPanel
- All Implemented Interfaces:
- Accessible, ImageObserver, MenuContainer, Runnable, Serializable
- public class DataPanel
- extends JSplitPane
- implements Runnable
This thread reads data from the DataReader
it then asks the appropriate HostDisplayPanel
to update its data.
- Version:
- $Id: DataPanel.java,v 1.30 2003/02/05 19:35:04 tdb Exp $
- Author:
- $Author: tdb $
- See Also:
- Serialized Form
Fields inherited from class javax.swing.JSplitPane |
BOTTOM, CONTINUOUS_LAYOUT_PROPERTY, continuousLayout, DIVIDER, DIVIDER_LOCATION_PROPERTY, DIVIDER_SIZE_PROPERTY, dividerSize, HORIZONTAL_SPLIT, LAST_DIVIDER_LOCATION_PROPERTY, lastDividerLocation, LEFT, leftComponent, ONE_TOUCH_EXPANDABLE_PROPERTY, oneTouchExpandable, orientation, ORIENTATION_PROPERTY, RESIZE_WEIGHT_PROPERTY, RIGHT, rightComponent, TOP, VERTICAL_SPLIT |
Fields inherited from class java.awt.Container |
|
Constructor Summary |
DataPanel()
Constructs the data panel |
Method Summary |
private void |
addHostPanel(String host)
Adds a new Host to the hostList and adds its
display to the tabbed pane. |
private void |
addToKnownHosts(String host)
If we are in "discovery" mode, we want to keep a list
of all new hosts we find, so we can add it to our list. |
void |
cleanUpTabs()
Removes all the tabs on display
Used to tidy up when a new data
channel is opened. |
private void |
refreshHostList()
Build the host list according to the configuration. |
void |
run()
Starts the DataPanel running |
void |
setQueue(Queue queue)
Assigns the queue that this panel
will use to obtain data |
void |
shutdown()
This method allows other classes
to shutdown this data panel. |
Methods inherited from class javax.swing.JSplitPane |
addImpl, getAccessibleContext, getBottomComponent, getDividerLocation, getDividerSize, getLastDividerLocation, getLeftComponent, getMaximumDividerLocation, getMinimumDividerLocation, getOrientation, getResizeWeight, getRightComponent, getTopComponent, getUI, getUIClassID, isContinuousLayout, isOneTouchExpandable, isValidateRoot, paintChildren, paramString, remove, remove, removeAll, resetToPreferredSizes, setBottomComponent, setContinuousLayout, setDividerLocation, setDividerLocation, setDividerSize, setLastDividerLocation, setLeftComponent, setOneTouchExpandable, setOrientation, setResizeWeight, setRightComponent, setTopComponent, setUI, updateUI |
Methods inherited from class javax.swing.JComponent |
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, paint, paintBorder, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, 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, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, 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, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, 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, processMouseEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, 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 |
REVISION
public final String REVISION
- The current CVS revision of this class
- See Also:
- Constant Field Values
_running
boolean _running
- The state of this thread.
_displayPaneLayout
private CardLayout _displayPaneLayout
- This card layout is used for the _displayPane
it allows the chooser list to select which
host to display
_displayPane
private JPanel _displayPane
- The panel where HostDisplayPanel's
are placed, it uses a CardLayout
_hostChooserList
private JList _hostChooserList
- The host list allows the user to select which
host pane is topmost
_dataQueue
private Queue _dataQueue
- The queue new data will be read from
_myQueue
int _myQueue
- Our queue number
_serverIcon
private ImageIcon _serverIcon
- An icon to represent a host
_qFrame
private QueueFrame _qFrame
- A frame to display Queue information
may not always be used - loaded according to config
_config
private Configuration _config
- A reference to the configuraton object
_hostList
private HashMap _hostList
- Contains a list of hosts that the data panel will use
or build during its operation.
_usingConfiguredList
boolean _usingConfiguredList
- If we should be using a configured list or just accepting
all the hosts we get
_xmlPacketMaker
private XMLPacketMaker _xmlPacketMaker
DataPanel
public DataPanel()
- Constructs the data panel
run
public void run()
- Starts the DataPanel running
- Specified by:
run
in interface Runnable
shutdown
public void shutdown()
- This method allows other classes
to shutdown this data panel.
refreshHostList
private void refreshHostList()
- Build the host list according to the configuration.
If we're set to use one, it populates the display.
If we're using one and its empty, or if we're not using
one, we set that we're not so that we use all host we detect.
See the run method for information on host discovery if we're
getting all the hosts.
addHostPanel
private void addHostPanel(String host)
- Adds a new Host to the hostList and adds its
display to the tabbed pane.
Ensures the host list is in alphabetical order.
- Parameters:
host
- the host to add
addToKnownHosts
private void addToKnownHosts(String host)
- If we are in "discovery" mode, we want to keep a list
of all new hosts we find, so we can add it to our list.
This method simply adds the host to the end of the
"knownHostList" property.
- Parameters:
host
- the host to add
cleanUpTabs
public void cleanUpTabs()
- Removes all the tabs on display
Used to tidy up when a new data
channel is opened.
setQueue
public void setQueue(Queue queue)
- Assigns the queue that this panel
will use to obtain data
- Parameters:
queue
- the queue
Copyright © 2000-2003 i-scream. All Rights Reserved.