Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.http.impl.nio.client
Class DefaultAsyncUserTokenHandler

    java.lang.Object
      org.apache.http.impl.nio.client.DefaultAsyncUserTokenHandler

All Implemented Interfaces:
  org.apache.http.client.UserTokenHandler

    @Contract(threading=IMMUTABLE)
    public class DefaultAsyncUserTokenHandler

extends Object
implements org.apache.http.client.UserTokenHandler

Default implementation of `UserTokenHandler` for asynchrounous HTTP client communication. This class will use an instance of `Principal` as a state object for non-blocking HTTP connections, if it can be obtained from the given execution context. This helps ensure persistent connections created with a particular user identity within a particular security context can be reused by the same user only.

This implementation will use the user principle of connection based authentication schemes such as NTLM or that of the SSL session with the client authentication turned on. If both are unavailable, `null` token will be returned.

Since:
  4.0

Field Summary
`static DefaultAsyncUserTokenHandler` | `INSTANCE`

Constructor Summary
`DefaultAsyncUserTokenHandler()`

Method Summary
`Object` | `getUserToken(org.apache.http.protocol.HttpContext context)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### INSTANCE

    public static final DefaultAsyncUserTokenHandler INSTANCE

Constructor Detail

### DefaultAsyncUserTokenHandler

    public DefaultAsyncUserTokenHandler()

Method Detail

### getUserToken

    public Object getUserToken(org.apache.http.protocol.HttpContext context)

  Specified by:
    `getUserToken` in interface `org.apache.http.client.UserTokenHandler`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2010–2021 The Apache Software Foundation. All rights reserved.