Constructor and Description |
---|
AuthToken() |
Modifier and Type | Method and Description |
---|---|
DateTime |
getExpiryDateTime()
Gets the timestamp when the current token expires.
|
String |
getPassword()
Gets the password, currently valid for authentication at the server.
|
DateTime |
getRenewalDateTime()
Gets the timestamp from which on a new token would be returned (but the old is still valid).
|
void |
makeUnmodifiable()
Makes this instance immutable.
|
void |
setExpiryDateTime(DateTime expiryDateTime)
Sets the timestamp when the current token expires.
|
void |
setPassword(String password)
Sets the current password.
|
void |
setRenewalDateTime(DateTime renewalDateTime) |
public AuthToken()
public String getPassword()
null
.public void setPassword(String password)
password
- the current password. Should not be null
.IllegalStateException
- after makeUnmodifiable()
was invoked.public DateTime getRenewalDateTime()
null
.public void setRenewalDateTime(DateTime renewalDateTime)
renewalDateTime
- IllegalStateException
- after makeUnmodifiable()
was invoked.public DateTime getExpiryDateTime()
Trying to authenticate with the current password
after this date + time
will fail.
null
.public void setExpiryDateTime(DateTime expiryDateTime)
expiryDateTime
- the timestamp when the current token expires. Should not be null
.IllegalStateException
- after makeUnmodifiable()
was invoked.public void makeUnmodifiable()
After this method was invoked, all setters throw an IllegalStateException
.
Copyright © 2013-2014. All Rights Reserved.