Package com.atlassian.bamboo.user
Class PasswordResetTokenImpl
java.lang.Object
com.atlassian.core.bean.EntityObject
com.atlassian.bamboo.core.BambooEntityObject
com.atlassian.bamboo.user.PasswordResetTokenImpl
- All Implemented Interfaces:
BambooIdProvider,BambooObject,PasswordResetToken,Cloneable
@Entity
public class PasswordResetTokenImpl
extends BambooEntityObject
implements PasswordResetToken
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedOnly used by Hibernate.PasswordResetTokenImpl(String userName) Creates new token and initializes it to random 50-char string and current time. -
Method Summary
Modifier and TypeMethodDescriptionvoidgenerate()Create new value of token and reset creation date to current time.@NotNull StringgetToken()@NotNull Timestampprotected voidprotected voidsetTokenCreationTime(@NotNull Timestamp tokenCreationTime) voidsetUserName(String userName) Methods inherited from class com.atlassian.core.bean.EntityObject
clone, equals, getCreationDate, getCurrentDate, getId, getLastModificationDate, hashCode, setClock, setCreationDate, setId, setLastModificationDateMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.atlassian.bamboo.core.BambooIdProvider
getIdMethods inherited from interface com.atlassian.bamboo.core.BambooObject
setId
-
Constructor Details
-
PasswordResetTokenImpl
protected PasswordResetTokenImpl()Only used by Hibernate. -
PasswordResetTokenImpl
Creates new token and initializes it to random 50-char string and current time.- Parameters:
userName- login name of a user
-
-
Method Details
-
getToken
- Specified by:
getTokenin interfacePasswordResetToken- Returns:
- value of a token
-
setToken
-
getTokenCreationTime
- Specified by:
getTokenCreationTimein interfacePasswordResetToken- Returns:
- time of creation
-
setTokenCreationTime
-
getUserName
- Specified by:
getUserNamein interfacePasswordResetToken- Returns:
- user login name
-
setUserName
-
generate
public void generate()Description copied from interface:PasswordResetTokenCreate new value of token and reset creation date to current time.- Specified by:
generatein interfacePasswordResetToken
-