Package com.codingchili.core.security
Class Account
java.lang.Object
com.codingchili.core.security.Account
- All Implemented Interfaces:
Storable
,io.vertx.core.shareddata.Shareable
,Serializable
,Cloneable
,Comparable
Transfer object used for authentication from clients.
Password is to be consumed once read.
- See Also:
- Serialized Form
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddProperty(String key, Object value)
boolean
getEmail()
getId()
Get the id of the storable item, used as a key to the map api.prefer using getCharPassword over this, as this method creates a new copy in memory of the password.int
hashCode()
setPassword(String password)
setProperties(Map<String,Object> properties)
setUsername(String username)
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.vertx.core.shareddata.Shareable
copy
Methods inherited from interface com.codingchili.core.storage.Storable
compareTo, compareToAttribute
-
Constructor Details
-
Account
public Account() -
Account
-
Account
-
-
Method Details
-
getUsername
-
setUsername
-
getPassword
prefer using getCharPassword over this, as this method creates a new copy in memory of the password. It is required for serialization purposes.- Returns:
- a copy of the raw char array as a string.
-
setPassword
-
getProperties
-
setProperties
-
addProperty
-
getEmail
-
setEmail
-
getId
Description copied from interface:Storable
Get the id of the storable item, used as a key to the map api. This field is not included when serializing to JSON. When serializing to json the id must be kept separately.instead of implementing this method, to avoid duplicate values in values as keys; implement hashCode based on an unique attribute combination.
-
hashCode
public int hashCode() -
equals
-