|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--java.awt.Panel
|
+--java.applet.Applet
|
+--javax.swing.JApplet
|
+--arlut.csd.ganymede.client.glogin
Ganymede client start class. This class can be run from the command line via its static main() method, or as an applet loaded into a web browser, generally with Sun's Java plug-in.
This class has a run() method for attempting to connect to the server in the background once the applet is initialized.
Once glogin handles the user's login, a gclient
object is constructed, which handles all of the user's interactions with the server.
| Inner classes inherited from class javax.swing.JApplet |
javax.swing.JApplet.AccessibleJApplet |
| Inner classes inherited from class java.applet.Applet |
java.applet.Applet.AccessibleApplet |
| Inner classes inherited from class java.awt.Panel |
java.awt.Panel.AccessibleAWTPanel |
| Inner classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
| Inner classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.AWTTreeLock |
| Field Summary | |
protected javax.swing.JButton |
_quitButton
|
private static java.awt.Container |
appletContentPane
|
private boolean |
autologin
|
protected javax.swing.JPanel |
bPanel
|
protected boolean |
connected
|
protected javax.swing.JButton |
connector
|
protected static DeathWatcherThread |
deathThread
Background thread to handle force disconnect commands from the server. |
static boolean |
debug
|
(package private) java.awt.Image |
errorImage
|
static gclient |
g_client
The main client class, will be null until the user is logged in to the server. |
protected java.awt.Image |
ganymede_logo
|
static java.util.Properties |
ganymedeProperties
Client-side properties loaded from the command line or from the web page which contains the definition for glogin as an applet. |
private java.awt.GridBagConstraints |
gbc
|
private java.awt.GridBagLayout |
gbl
|
static java.lang.String |
helpBase
|
protected static ClientBase |
my_client
RMI object to handle getting us logged into the server, and to handle asynchronous callbacks from the server on our behalf. |
protected static javax.swing.JFrame |
my_frame
If we are run from the command line, this frame will be used to contain the glogin applet in an application context. |
protected static glogin |
my_glogin
We're a singleton pattern.. |
protected static java.lang.String |
my_passwd
|
protected static Server |
my_server
Reference to the server acquired by RMI naming service. |
protected static Session |
my_session
Reference to a user session on the server, will be null until the user is logged into the server. |
protected java.lang.Thread |
my_thread
Background thread used to attempt to get the initial RMI connection to the Ganymede server. |
protected static java.lang.String |
my_username
|
protected javax.swing.JPasswordField |
passwd
|
static java.lang.String |
properties_file
|
static int |
registryPortProperty
|
static java.lang.String |
server_url
|
static java.lang.String |
serverhost
|
protected javax.swing.JTextField |
username
|
private static boolean |
WeAreApplet
If true, we are running as an applet and are limited by the Java sandbox. |
| Fields inherited from class javax.swing.JApplet |
accessibleContext, rootPane, rootPaneCheckingEnabled |
| Fields inherited from class java.applet.Applet |
serialVersionUID, stub |
| Fields inherited from class java.awt.Panel |
base, nameCounter |
| Fields inherited from class java.awt.Container |
component, containerListener, containerSerializedDataVersion, dbg, dispatcher, layoutMgr, listeningBoundsChildren, listeningChildren, maxSize, ncomponents, printing, printingThreads |
| Fields inherited from class java.awt.Component |
actionListenerK, adjustmentListenerK, appContext, background, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, changeSupport, componentListener, componentListenerK, componentOrientation, componentSerializedDataVersion, containerListenerK, cursor, dropTarget, enabled, eventMask, focusListener, focusListenerK, font, foreground, graphicsConfig, hasFocus, height, hierarchyBoundsListener, hierarchyBoundsListenerK, hierarchyListener, hierarchyListenerK, incRate, inputMethodListener, inputMethodListenerK, isInc, isPacked, itemListenerK, keyListener, keyListenerK, LEFT_ALIGNMENT, locale, LOCK, metrics, minSize, mouseListener, mouseListenerK, mouseMotionListener, mouseMotionListenerK, name, nameExplicitlySet, newEventsOnly, ownedWindowK, parent, peer, peerFont, popups, prefSize, privateKey, RIGHT_ALIGNMENT, textListenerK, TOP_ALIGNMENT, valid, visible, width, windowClosingException, windowListenerK, x, y |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
glogin()
|
|
| Method Summary | |
void |
actionPerformed(java.awt.event.ActionEvent e)
Handle button clicks, and enter being hit in the password field. |
void |
destroy()
If the applet is no longer visible on the page, we exit. |
void |
disconnected(ClientEvent e)
Handle a forced disconnect message from the ClientBase RMI object. |
void |
enableButtons(boolean enabled)
|
java.awt.Image |
getErrorImage()
Loads and returns the error Image for use in client dialogs. |
java.lang.String |
getUserName()
Reports our username to gclient |
void |
init()
Standard applet initialization method. |
static boolean |
isApplet()
This method returns true if the Ganymede client is running as an applet. |
void |
logout()
Logout from the server. |
static void |
main(java.lang.String[] args)
This main() function will allow this applet to run as an application when it is not executed in the context of a browser. |
void |
messageReceived(ClientEvent e)
Handle a message from the ClientBase
RMI object. |
void |
run()
This will be executed in the thread that tries to connect to the server. |
void |
setNormalCursor()
Set the cursor to the normal cursor(usually a pointer). |
void |
setWaitCursor()
Set the cursor to a wait cursor(usually a watch.) |
private void |
startSession(Session session)
Starts the main Ganymede client. |
| Methods inherited from class javax.swing.JApplet |
addImpl, createRootPane, createRootPaneException, getAccessibleContext, getContentPane, getGlassPane, getJMenuBar, getLayeredPane, getRootPane, isRootPaneCheckingEnabled, paramString, processKeyEvent, remove, setContentPane, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update |
| Methods inherited from class java.applet.Applet |
getAppletContext, getAppletInfo, getAudioClip, getAudioClip, getCodeBase, getDocumentBase, getImage, getImage, getLocale, getParameter, getParameterInfo, isActive, newAudioClip, play, play, resize, resize, setStub, showStatus, start, stop |
| Methods inherited from class java.awt.Panel |
|
| Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, adjustListeningChildren, applyOrientation, checkGD, countComponents, createChildHierarchyEvents, createHierarchyEvents, deliverEvent, dispatchEventImpl, dispatchEventToSelf, doLayout, eventEnabled, findComponentAt, findComponentAt, findComponentAt, getAccessibleAt, getAccessibleChild, getAccessibleChildrenCount, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents_NoClientCode, getComponents, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getMouseEventTarget, getPreferredSize, getWindow, initIDs, insets, invalidate, invalidateTree, isAncestorOf, layout, lightweightPaint, lightweightPrint, list, list, locate, minimumSize, nextFocus, numListening, paint, paintComponents, paintHeavyweightComponents, postProcessKeyEvent, postsOldMouseEvents, preferredSize, preProcessKeyEvent, print, printComponents, printHeavyweightComponents, processContainerEvent, processEvent, proxyEnableEvents, proxyRequestFocus, readObject, remove, removeAll, removeContainerListener, removeNotify, setFocusOwner, setFont, transferFocus, validate, validateTree, writeObject |
| Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, areInputMethodsEnabled, bounds, checkImage, checkImage, checkWindowClosingException, coalesceEvents, contains, contains, createImage, createImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getAccessibleIndexInParent, getAccessibleStateSet, getBackground, getBounds, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont_NoClientCode, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getInputContext, getInputMethodRequests, getLocation, getLocation, getLocationOnScreen_NoTreeLock, getLocationOnScreen, getName, getNativeContainer, getParent_NoClientCode, getParent, getPeer, getSize, getSize, getToolkit, getToolkitImpl, getTreeLock, getWidth, getWindowForObject, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isDisplayable, isDoubleBuffered, isEnabled, isEnabledImpl, isFocusTraversable, isLightweight, isOpaque, isRecursivelyVisible, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, processMouseMotionEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, resetGC, reshape, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, size, toString, transferFocus |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait |
| Field Detail |
public static boolean debug
public static java.lang.String properties_file
public static java.lang.String serverhost
public static java.lang.String server_url
public static java.lang.String helpBase
public static int registryPortProperty
public static java.util.Properties ganymedeProperties
public static gclient g_client
protected static javax.swing.JFrame my_frame
protected static Server my_server
protected static ClientBase my_client
protected static Session my_session
protected static java.lang.String my_username
protected static java.lang.String my_passwd
protected static glogin my_glogin
private static boolean WeAreApplet
private static java.awt.Container appletContentPane
protected static DeathWatcherThread deathThread
protected java.lang.Thread my_thread
protected boolean connected
private boolean autologin
private java.awt.GridBagLayout gbl
private java.awt.GridBagConstraints gbc
java.awt.Image errorImage
protected java.awt.Image ganymede_logo
protected javax.swing.JTextField username
protected javax.swing.JPasswordField passwd
protected javax.swing.JButton connector
protected javax.swing.JButton _quitButton
protected javax.swing.JPanel bPanel
| Constructor Detail |
public glogin()
| Method Detail |
public static void main(java.lang.String[] args)
public static boolean isApplet()
public void init()
init in class java.applet.Appletpublic void run()
run in interface java.lang.Runnablepublic void logout()
public void destroy()
destroy in class java.applet.Appletpublic java.lang.String getUserName()
public void enableButtons(boolean enabled)
public void setWaitCursor()
public void setNormalCursor()
Set the cursor to the normal cursor(usually a pointer).
This is dependent on the operating system.
public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed in interface java.awt.event.ActionListenerprivate void startSession(Session session)
public void messageReceived(ClientEvent e)
ClientBase
RMI object.messageReceived in interface ClientListenerpublic void disconnected(ClientEvent e)
ClientBase RMI object.disconnected in interface ClientListenerpublic final java.awt.Image getErrorImage()
Loads and returns the error Image for use in client dialogs.
Once the image is loaded, it is cached for future calls to getErrorImage().
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||