Class SSOLoginService

java.lang.Object
org.jdesktop.beans.AbstractBean
org.jdesktop.swingx.auth.LoginService
be.gaudry.swing.authentication.SSOLoginService
Direct Known Subclasses:
EduAdminLoginService, EduTeacherLoginService

public abstract class SSOLoginService extends org.jdesktop.swingx.auth.LoginService
"Single Sign On" login mechanism. Provided by the broldev.core.swing project.
Since:
1.0 (Oct 17, 2010), broldev.core.swing 0.0.1-SNAPSHOT dependency
Version:
1.0 (Oct 17, 2010)
Author:
Steph GAUDRY
  • Constructor Summary

    Constructors
    Constructor
    Description
    Builds a default instance of the Single Sign On
    Builds a custom instance of the Single Sign On
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    authenticate​(String name, char[] password, String server)
     
    abstract boolean
    authenticateOnce​(String name, char[] password, String server)
    This method is intended to be implemented by clients wishing to authenticate a user with a given password.
    boolean
    Status of the Single Sign On.
    void
    Sets this instance into an unauthenticated state, as at the beginning.

    Methods inherited from class org.jdesktop.swingx.auth.LoginService

    addLoginListener, cancelAuthentication, getServer, getSynchronous, getUserRoles, removeLoginListener, setServer, setSynchronous, startAuthentication

    Methods inherited from class org.jdesktop.beans.AbstractBean

    addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, clone, fireIndexedPropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, getPropertyChangeListeners, getPropertyChangeListeners, getVetoableChangeListeners, getVetoableChangeListeners, hasPropertyChangeListeners, hasVetoableChangeListeners, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener

    Methods inherited from class java.lang.Object

    equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • SSOLoginService

      public SSOLoginService()
      Builds a default instance of the Single Sign On
    • SSOLoginService

      public SSOLoginService(String server)
      Builds a custom instance of the Single Sign On
      Parameters:
      server - of the login service
  • Method Details

    • logOff

      public void logOff()
      Sets this instance into an unauthenticated state, as at the beginning. That means the next time the authenticate method will be invoked the authentication mechanism will be called again.
    • isAuthenticated

      public boolean isAuthenticated()
      Status of the Single Sign On.
      Returns:
      true if the last authentication has not fail
    • authenticate

      public final boolean authenticate(String name, char[] password, String server) throws Exception
      Specified by:
      authenticate in class org.jdesktop.swingx.auth.LoginService
      Throws:
      Exception
    • authenticateOnce

      public abstract boolean authenticateOnce(String name, char[] password, String server) throws Exception
      This method is intended to be implemented by clients wishing to authenticate a user with a given password. \nThis mechanism is called only on the "unauthenticated" state. To return to the initial "unauthenticated" state, you may call the logOff() method.
      Parameters:
      name - user name
      password - user password
      server - server (optional)
      Returns:
      true on authentication success
      Throws:
      Exception
      See Also:
      logOff(), isAuthenticated()