public class ChannelAuthToken extends java.lang.Object implements ChannelAuth
| Constructor and Description |
|---|
ChannelAuthToken(java.lang.String token) |
| Modifier and Type | Method and Description |
|---|---|
void |
authenticate(org.apache.http.HttpRequest httpRequest)
Adds the http header with the Authorization token to the given http request
|
void |
reset()
This method does no operation in
ChannelAuthToken class. |
public ChannelAuthToken(java.lang.String token)
token - token value to use in the Authorization HTTP Header. The token is added to HTTP requests when
the authenticate(HttpRequest) method is invoked.public void authenticate(org.apache.http.HttpRequest httpRequest)
authenticate in interface ChannelAuthhttpRequest - request where to add the Authorization headerpublic void reset()
ChannelAuthToken class. If a new token has to be provided, then
it is necessary to create a new ChannelAuthToken instance and provide the new token to the
ChannelAuthToken(String) constructor.reset in interface ChannelAuth