Class User
- java.lang.Object
-
- io.mateu.mdd.core.model.authentication.User
-
- All Implemented Interfaces:
io.mateu.mdd.shared.interfaces.UserPrincipal,io.mateu.util.interfaces.EditorViewStyler
- Direct Known Subclasses:
AdminUser
@Entity public class User extends Object implements io.mateu.util.interfaces.EditorViewStyler, io.mateu.mdd.shared.interfaces.UserPrincipal
holder for users of our common. It can be an internal user or a user created for a customer or a supplier Created by miguel on 13/9/16.
-
-
Constructor Summary
Constructors Constructor Description User()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidapply(com.vaadin.ui.Component editorViewComponent)booleancheckPassword(String password)URLgetPhoto()List<String>getRoles()booleanhasPermission(long permissionId)voidpost()voidprePersist()voidresetPassword()voidsendEmail(Template template, String subject, String postscript)static voidsendEmail(Template template, String subject, String postscript, Set<User> selectedUsers)StringsendForgottenPasswordEmail(javax.persistence.EntityManager em)voidsendWelcomeEmail()StringsendWelcomeEmail(javax.persistence.EntityManager em)voidsetLogin(String login)voidsetPassword(String password)StringtoString()
-
-
-
Method Detail
-
setPassword
public void setPassword(String password)
-
checkPassword
public boolean checkPassword(String password)
-
setLogin
public void setLogin(String login)
-
prePersist
public void prePersist()
-
resetPassword
public void resetPassword()
-
sendWelcomeEmail
public String sendWelcomeEmail(javax.persistence.EntityManager em) throws Throwable
- Throws:
Throwable
-
sendForgottenPasswordEmail
public String sendForgottenPasswordEmail(javax.persistence.EntityManager em) throws Throwable
- Throws:
Throwable
-
post
public void post()
-
sendEmail
public void sendEmail(Template template, String subject, String postscript) throws Throwable
- Throws:
Throwable
-
sendEmail
public static void sendEmail(Template template, String subject, String postscript, Set<User> selectedUsers) throws Throwable
- Throws:
Throwable
-
hasPermission
public boolean hasPermission(long permissionId)
-
apply
public void apply(com.vaadin.ui.Component editorViewComponent)
- Specified by:
applyin interfaceio.mateu.util.interfaces.EditorViewStyler
-
getRoles
public List<String> getRoles()
- Specified by:
getRolesin interfaceio.mateu.mdd.shared.interfaces.UserPrincipal
-
getPhoto
public URL getPhoto()
- Specified by:
getPhotoin interfaceio.mateu.mdd.shared.interfaces.UserPrincipal
-
-