models.entity
Class User

java.lang.Object
  extended by play.db.ebean.Model
      extended by models.entity.User
All Implemented Interfaces:
be.objectify.deadbolt.core.models.Subject, com.avaje.ebean.bean.EntityBean, java.io.Serializable

@Entity
public class User
extends play.db.ebean.Model
implements be.objectify.deadbolt.core.models.Subject

user of geoPortal

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class play.db.ebean.Model
play.db.ebean.Model.Finder<I,T>
 
Field Summary
static play.db.ebean.Model.Finder<java.lang.Long,User> find
           
 
Fields inherited from class play.db.ebean.Model
_ebean_identity, _ebean_intercept
 
Constructor Summary
User()
          constructor
 
Method Summary
static User auth(java.lang.String login, java.lang.String hashPass)
          find user by login and password
static User findById(java.lang.Long userId)
          find user by id
 java.lang.Long getId()
           
 java.lang.String getIdentifier()
           
 java.lang.String getLogin()
           
 java.lang.String getName()
           
 java.lang.String getPassword()
           
 java.util.List<? extends be.objectify.deadbolt.core.models.Permission> getPermissions()
           
 Right getRight()
           
 java.util.List<? extends be.objectify.deadbolt.core.models.Role> getRoles()
           
 void setId(java.lang.Long id)
          set user id
 void setLogin(java.lang.String login)
          set user login
 void setName(java.lang.String name)
           
 void setPassword(java.lang.String password)
           
 void setRight(Right right)
           
 
Methods inherited from class play.db.ebean.Model
_ebean_createCopy, _ebean_get__idGetSet, _ebean_getField, _ebean_getFieldIntercept, _ebean_getFieldNames, _ebean_getIntercept, _ebean_getMarker, _ebean_getni__idGetSet, _ebean_intercept, _ebean_isEmbeddedNewOrDirty, _ebean_newInstance, _ebean_set__idGetSet, _ebean_setEmbeddedLoaded, _ebean_setField, _ebean_setFieldIntercept, _ebean_setni__idGetSet, addPropertyChangeListener, addPropertyChangeListener, delete, delete, deleteManyToManyAssociations, equals, hashCode, refresh, refresh, removePropertyChangeListener, removePropertyChangeListener, save, save, saveManyToManyAssociations, saveManyToManyAssociations, update, update, update, update
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

find

public static play.db.ebean.Model.Finder<java.lang.Long,User> find
See Also:
Finder
Constructor Detail

User

public User()
constructor

Method Detail

getId

public java.lang.Long getId()
Returns:
user id

setId

public void setId(java.lang.Long id)
set user id

Parameters:
id - user id

getLogin

public java.lang.String getLogin()
Returns:
login

setLogin

public void setLogin(java.lang.String login)
set user login

Parameters:
login - login

getPassword

public java.lang.String getPassword()
Returns:
user password

setPassword

public void setPassword(java.lang.String password)
Parameters:
password - user password

getName

public java.lang.String getName()
Returns:
user name

setName

public void setName(java.lang.String name)
Parameters:
name - user name

getRight

public Right getRight()
Returns:
user right
See Also:
Right

setRight

public void setRight(Right right)
Parameters:
right - Right object
See Also:
Right

auth

public static User auth(java.lang.String login,
                        java.lang.String hashPass)
find user by login and password

Parameters:
login -
hashPass - md5 of password
Returns:
User object or null

findById

public static User findById(java.lang.Long userId)
find user by id

Parameters:
userId -
Returns:
User object or null

getRoles

public java.util.List<? extends be.objectify.deadbolt.core.models.Role> getRoles()
Specified by:
getRoles in interface be.objectify.deadbolt.core.models.Subject

getPermissions

public java.util.List<? extends be.objectify.deadbolt.core.models.Permission> getPermissions()
Specified by:
getPermissions in interface be.objectify.deadbolt.core.models.Subject

getIdentifier

public java.lang.String getIdentifier()
Specified by:
getIdentifier in interface be.objectify.deadbolt.core.models.Subject