com.adventnet.snmp.snmp2
Class SASAppletStub

java.lang.Object
  |
  +--com.adventnet.snmp.snmp2.SASAppletStub
All Implemented Interfaces:
java.applet.AppletStub

public class SASAppletStub
extends java.lang.Object
implements java.applet.AppletStub

This class provides the implementation of the AppletStub methods to plug into applet to simulate the applet behaviour. This class is used when we have to pass a 'user-defined applet' to the SnmpSession's open() while using client applications (instead of applets) with SAS.


Constructor Summary
SASAppletStub()
          Constructor that creates the implementation of the AppletStub.
 
Method Summary
 void appletResize(int width, int height)
          Called when the applet wants to be resized.
 java.applet.AppletContext getAppletContext()
          Gets a handler to the applet's context.
 java.net.URL getCodeBase()
          Gets the base URL.
 java.net.URL getDocumentBase()
          Gets the document URL.
 java.lang.String getParameter(java.lang.String name)
          Returns the value of the named parameter in the HTML tag.
 boolean isActive()
          Determines if the applet is active.
 void setAppletContext(java.applet.AppletContext context)
          Sets the applet context to the user specified one.
 void setCodeBase(java.net.URL url)
          Sets the codebase URL.
 void setDocumentBase(java.net.URL url)
          Sets the document URL.
 void setParameter(java.lang.String name, java.lang.String value)
          Sets the name-value pair in the applet parameter.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SASAppletStub

public SASAppletStub()
Constructor that creates the implementation of the AppletStub.
Method Detail

appletResize

public void appletResize(int width,
                         int height)
Called when the applet wants to be resized.
Specified by:
appletResize in interface java.applet.AppletStub

getCodeBase

public java.net.URL getCodeBase()
Gets the base URL.
Specified by:
getCodeBase in interface java.applet.AppletStub

setCodeBase

public void setCodeBase(java.net.URL url)
Sets the codebase URL.

getDocumentBase

public java.net.URL getDocumentBase()
Gets the document URL.
Specified by:
getDocumentBase in interface java.applet.AppletStub

setDocumentBase

public void setDocumentBase(java.net.URL url)
Sets the document URL.

getParameter

public java.lang.String getParameter(java.lang.String name)
Returns the value of the named parameter in the HTML tag.
Specified by:
getParameter in interface java.applet.AppletStub

getAppletContext

public java.applet.AppletContext getAppletContext()
Gets a handler to the applet's context.
Specified by:
getAppletContext in interface java.applet.AppletStub

isActive

public boolean isActive()
Determines if the applet is active.
Specified by:
isActive in interface java.applet.AppletStub

setParameter

public void setParameter(java.lang.String name,
                         java.lang.String value)
                  throws java.lang.NullPointerException
Sets the name-value pair in the applet parameter. These values are retrieved by the getParameter() method.
Parameters:
name - The name of the parameter to add.
value - The value of the specified parameter
Throws:
java.lang.NullPointerException - is the name or value is null.

setAppletContext

public void setAppletContext(java.applet.AppletContext context)
Sets the applet context to the user specified one. Normally user may not need to use this, but in case you need to plug-in your own applet context, then use this API.


Copyright (c)AdventNet Inc., 1996-2004