org.apache.servicemix.http
Class BasicAuthCredentials

java.lang.Object
  extended by org.apache.servicemix.http.BasicAuthCredentials

public class BasicAuthCredentials
extends java.lang.Object

Author:
roehl.sioson

Field Summary
protected  org.apache.servicemix.expression.Expression domain
           
protected  org.apache.servicemix.expression.Expression host
           
protected  org.apache.servicemix.expression.Expression password
           
protected  org.apache.servicemix.expression.Expression username
           
 
Constructor Summary
BasicAuthCredentials()
           
 
Method Summary
 void applyCredentials(org.apache.commons.httpclient.HttpClient client, javax.jbi.messaging.MessageExchange exchange, javax.jbi.messaging.NormalizedMessage message, org.apache.commons.httpclient.HostConfiguration hostConfig)
          Applies this authentication to the given method.
 void applyProxyCredentials(org.apache.commons.httpclient.HttpClient client, javax.jbi.messaging.MessageExchange exchange, javax.jbi.messaging.NormalizedMessage message)
          Applies this authentication to the given method.
 org.apache.servicemix.expression.Expression getDomain()
          Returns the domain for NTLM authentication.
 org.apache.servicemix.expression.Expression getHost()
          Returns the host for NTLM authentication.
 org.apache.servicemix.expression.Expression getPassword()
          Returns the password for authentication.
 org.apache.servicemix.expression.Expression getUsername()
          Returns the username for authentication.
 void setDomain(org.apache.servicemix.expression.Expression domain)
          Sets the domain to use for NTLM authentication.
 void setHost(org.apache.servicemix.expression.Expression host)
          Sets the host to use for NTLM authentication.
 void setPassword(org.apache.servicemix.expression.Expression password)
          Sets the password to use for authentication.
 void setUsername(org.apache.servicemix.expression.Expression username)
          Sets the username to use for authentocation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

username

protected org.apache.servicemix.expression.Expression username

password

protected org.apache.servicemix.expression.Expression password

host

protected org.apache.servicemix.expression.Expression host

domain

protected org.apache.servicemix.expression.Expression domain
Constructor Detail

BasicAuthCredentials

public BasicAuthCredentials()
Method Detail

getUsername

public org.apache.servicemix.expression.Expression getUsername()
Returns the username for authentication.

Returns:
an Expression containing the username

setUsername

public void setUsername(org.apache.servicemix.expression.Expression username)
Sets the username to use for authentocation.

Parameters:
username - am Expression containing the username.

getPassword

public org.apache.servicemix.expression.Expression getPassword()
Returns the password for authentication.

Returns:
an Expression containing the password

setPassword

public void setPassword(org.apache.servicemix.expression.Expression password)
Sets the password to use for authentication.

Parameters:
password - an Expression containing the password.

getDomain

public org.apache.servicemix.expression.Expression getDomain()
Returns the domain for NTLM authentication.

Returns:
an Expression containing the NTLM domain.

setDomain

public void setDomain(org.apache.servicemix.expression.Expression domain)
Sets the domain to use for NTLM authentication.

Parameters:
domain - an Expression containing the NTLM domain.

getHost

public org.apache.servicemix.expression.Expression getHost()
Returns the host for NTLM authentication.

Returns:
an Expression containing the NTLM host.

setHost

public void setHost(org.apache.servicemix.expression.Expression host)
Sets the host to use for NTLM authentication.

Parameters:
host - an Expression containing the NTLM host.

applyCredentials

public void applyCredentials(org.apache.commons.httpclient.HttpClient client,
                             javax.jbi.messaging.MessageExchange exchange,
                             javax.jbi.messaging.NormalizedMessage message,
                             org.apache.commons.httpclient.HostConfiguration hostConfig)
                      throws javax.jbi.messaging.MessagingException
Applies this authentication to the given method.

Parameters:
client - the client on which to set the authentication information
exchange - the message exchange to be used for evaluating the expression
message - the normalized message to be used for evaluating the expression
hostConfig - optional but if set the AuthScope is bind to that host and port from that hostConfig
Throws:
javax.jbi.messaging.MessagingException - if the correct value for username/password cannot be determined when using an expression

applyProxyCredentials

public void applyProxyCredentials(org.apache.commons.httpclient.HttpClient client,
                                  javax.jbi.messaging.MessageExchange exchange,
                                  javax.jbi.messaging.NormalizedMessage message)
                           throws javax.jbi.messaging.MessagingException
Applies this authentication to the given method.

Parameters:
client - the client on which to set the authentication information
exchange - the message exchange to be used for evaluating the expression
message - the normalized message to be used for evaluating the expression
Throws:
javax.jbi.messaging.MessagingException - if the correct value for user name/password cannot be determined when using an expression


Copyright © 2005-2012 FuseSource. All Rights Reserved.