Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.runtime.api.login
Class DefaultCallbackHandler

java.lang.Object
  extended by org.nuxeo.runtime.api.login.DefaultCallbackHandler
All Implemented Interfaces:
CallbackHandler

public class DefaultCallbackHandler
extends Object
implements CallbackHandler

Copied from jbossx.

Author:
Scott.Stark@jboss.org

Constructor Summary
DefaultCallbackHandler(String username, char[] password)
          Initializes the UsernamePasswordHandler with the username and password to use.
DefaultCallbackHandler(String username, Object credential)
           
 
Method Summary
 void handle(Callback[] callbacks)
          Sets any NameCallback name property to the instance username, sets any PasswordCallback password property to the instance, and any password.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultCallbackHandler

public DefaultCallbackHandler(String username,
                              char[] password)
Initializes the UsernamePasswordHandler with the username and password to use.

Parameters:
username - the user name
password - the password for this user

DefaultCallbackHandler

public DefaultCallbackHandler(String username,
                              Object credential)
Method Detail

handle

public void handle(Callback[] callbacks)
            throws UnsupportedCallbackException
Sets any NameCallback name property to the instance username, sets any PasswordCallback password property to the instance, and any password.

Specified by:
handle in interface CallbackHandler
Throws:
UnsupportedCallbackException, - thrown if any callback of type other than NameCallback or PasswordCallback are seen.
UnsupportedCallbackException

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.