Class PInfranetApplet

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer
Direct Known Subclasses:
PSimpleApplet

public class PInfranetApplet extends JApplet
PInfranetApplet is a JApplet extension that provides the basic functionality needed by all Portal-aware applets.
Version:
6
Author:
Larry Lynch-Freshner
See Also:
  • Constructor Details

    • PInfranetApplet

      public PInfranetApplet()
      Creates a default instance of PInfranetApplet.
  • Method Details

    • init

      public void init()
      Overrides the Applet.init() method. Subclasses that override this version of the init() method must call it first.
      Overrides:
      init in class Applet
    • start

      public void start()
      Overrides the Applet.start() method and issues a PContextChangedEvent. Be sure to call the super class if overridden.
      Overrides:
      start in class Applet
    • stop

      public void stop()
      Overrides the Applet.stop() method and issues a PContextChangedEvent. Be sure to call the super class if overridden.
      Overrides:
      stop in class Applet
    • destroy

      public void destroy()
      Overrides the Applet.destroy() method and issues a PContextChangedEvent. Be sure to call the super class if overridden.
      Overrides:
      destroy in class Applet
    • getServices

      public PClientServices getServices()
      A utility method that gets the client services.
      Returns:
      A client services object.
    • displayDefaultLogin

      protected void displayDefaultLogin()
      A utility method that displays a simple user/password login screen in the applet. It calls handleLoginAccepted if a valid login occurs.
    • displayLogin

      protected void displayLogin(JComponent login)
      A utility method that displays a specified login panel. This panel must conform to the following rules to work properly:

      1. To perform the actual login, it must call PClientServices.doLogin().
      2. If the login is accepted, it should call handleLoginAccepted, preferably in a separate thread.
      3. If the login is not accepted, it should display a dialog to notify the user.

      Parameters:
      login - the user's login information
      See Also:
    • handleLoginAccepted

      public void handleLoginAccepted()
      A default login handler. Gets the object pointed to by the "screen" property/parameter. If the object is a URL, then the browser is directed there. Otherwise, it is assumed to be a bean to load and display.
    • loadComponent

      protected void loadComponent(String name)
      A utility method that attempts to load and display a bean into this applet.
      Parameters:
      name - the class name for the bean