com.sshtools.virtualsession.status
Interface StatusBar

All Superinterfaces:
VirtualSessionComponent
All Known Subinterfaces:
TerminalStatusBar
All Known Implementing Classes:
AWTStatusBar, AWTTerminalStatusBar, SwingStatusBar, SwingTerminalStatusBar

public interface StatusBar
extends VirtualSessionComponent

Suitable for use with components that provide some kind off status bar made up of many different StatusElement implementations. For example, the Swing terminal toolkit provides a component that will show each element as a label that appears slighly indented.

Each element must provide a 'weight' that determines the proportion of the entire StatusBar it will take up. For ease of use, the weight value should follow the same rules as for the standard AWT java.awt.GridBagConstratins.weightx.

Author:
$Author: james $

Method Summary
 void addElement(StatusElement element)
          Add an element to the status bar.
 void removeAllElements()
          Remove all of the status elements from the status bar.
 void setSeparators(boolean seperators)
          Set whether separators should be placed between each element
 
Methods inherited from interface com.sshtools.virtualsession.ui.VirtualSessionComponent
getComponent, getTerminalDisplay, init
 

Method Detail

addElement

void addElement(StatusElement element)
                throws java.lang.IllegalArgumentException
Add an element to the status bar. The status bar may impose restrictions on the type of this element, such as it being an instance of a java.awt.Component in the case of SwingStatusBar and AWTStatusBar.

Parameters:
element - element to add
Throws:
java.lang.IllegalArgumentException - if element is of wrong type

removeAllElements

void removeAllElements()
Remove all of the status elements from the status bar.


setSeparators

void setSeparators(boolean seperators)
Set whether separators should be placed between each element

Parameters:
seperators - use separators


Copyright © 2003-2004 3SP LTD. All Rights Reserved.