|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
java.awt.Container
java.awt.Panel
java.applet.Applet
mil.navy.nps.awt.AwtPduViewer
AwtPduViewer is an applet that reads Pdus and displays their values on the screen. It is configured with a socket, which allows the applet to read data from the wire; it uses the package mil.navy.nps.dis, which implements the DIS protocol.
This file was generated by Microsquish J++, which is something of an experiment. We'll see how it works out. It's also my first applet that isn't completely trivial, so be a little gentle.
This is compliant with the JDK 1.02 spec; it makes use of deprecated aspects of that API rather than use JDK 1.1. This is primarily to get it working with Netscape 3.01. 1.1 browser implementations should be compatible, at least for the next release.
Netscape bitches & moans about doing a thread.suspend(), complaining about the possibility of deadlock. Not sure what this is all about, but it seems to work. (Note: JavaSoft has deprecated thread.suspend() and friends in 1.1 because of inherent problems w/ deadlock. This needs to be reworked.
This takes two parameters from the HTML file, "PduSocket" and"MulticastGroup". The first is the socket the applet listens on. The second is a multicast group, a feature that is not implemented right now since Netscape doesn't do multicast.
Testing: sent ESPdus to host (madison) from both madison and pinafore using mil.navy.nps.dis.Benchmark. HISTORY
10Apr97 DMcG New
UpdateThread
,
TextAreaStream
,
Serialized FormNested Class Summary |
Nested classes inherited from class java.applet.Applet |
java.applet.Applet.AccessibleApplet |
Nested classes inherited from class java.awt.Panel |
java.awt.Panel.AccessibleAWTPanel |
Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary |
Fields inherited from class java.applet.Applet |
|
Fields inherited from class java.awt.Container |
|
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 | |
AwtPduViewer()
|
Method Summary | |
void |
actionPerformed(java.awt.event.ActionEvent e)
Handles button presses |
void |
destroy()
|
java.lang.String |
getAppletInfo()
|
java.lang.String[][] |
getParameterInfo()
|
void |
init()
Applet initialization code |
void |
itemStateChanged(java.awt.event.ItemEvent ie)
itemStateChanged is the interface for ItemListener. |
void |
paint(java.awt.Graphics g)
|
void |
run()
|
void |
start()
|
void |
stop()
|
void |
updateDisplay()
Updates the display by querying the BehaviorStreamBufferUDP, returning any Pdus that have arrived since the last time we asked, and updating the display. |
Methods inherited from class java.applet.Applet |
getAccessibleContext, getAppletContext, getAudioClip, getAudioClip, getCodeBase, getDocumentBase, getImage, getImage, getLocale, getParameter, isActive, newAudioClip, play, play, resize, resize, setStub, showStatus |
Methods inherited from class java.awt.Panel |
addNotify |
Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, paramString, preferredSize, print, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, removeNotify, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setFont, setLayout, transferFocusBackward, transferFocusDownCycle, update, 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, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isOpaque, 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, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusUpCycle |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public AwtPduViewer()
Method Detail |
public java.lang.String getAppletInfo()
public java.lang.String[][] getParameterInfo()
public void init()
public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed
in interface java.awt.event.ActionListener
public void destroy()
public void paint(java.awt.Graphics g)
public void start()
public void stop()
public void run()
run
in interface java.lang.Runnable
public void updateDisplay()
public void itemStateChanged(java.awt.event.ItemEvent ie)
itemStateChanged
in interface java.awt.event.ItemListener
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |