KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jboss > portal > core > model > User


1 /*****************************************
2  * *
3  * JBoss Portal: The OpenSource Portal *
4  * *
5  * Distributable under LGPL license. *
6  * See terms of license at gnu.org. *
7  * *
8  *****************************************/

9 package org.jboss.portal.core.model;
10
11 import java.util.Date JavaDoc;
12 import java.util.Set JavaDoc;
13
14 import org.jboss.portal.server.plugins.preferences.PreferenceStore;
15
16 /**
17  * A user.
18  *
19  * @author <a HREF="mailto:julien@jboss.org">Julien Viet</a>
20  * @author <a HREF="mailto:theute@jboss.org">Thomas Heute</a>
21  * @version $Revision: 1.6 $
22  */

23 public interface User
24 {
25    /**
26     * The user identifier.
27     *
28     * @return the user ID
29     */

30    Integer JavaDoc getID();
31
32    /**
33     * The user name.
34     *
35     * @return the user name
36     */

37    String JavaDoc getUserName();
38
39    /**
40     * The given name.
41     *
42     * @return the given name (firstname)
43     */

44    String JavaDoc getGivenName();
45    
46    void setGivenName(String JavaDoc givenName);
47    
48    /**
49     * The family name.
50     *
51     * @return the family name
52     */

53    String JavaDoc getFamilyName();
54
55    void setFamilyName(String JavaDoc familyName);
56
57     /**
58     *
59     */

60    String JavaDoc getRealEmail();
61
62    void setRealEmail(String JavaDoc realEmail);
63    
64    String JavaDoc getFakeEmail();
65
66    void setFakeEmail(String JavaDoc fakeEmail);
67    
68    Date JavaDoc getRegistrationDate();
69    
70    void setRegistrationDate(Date JavaDoc registrationDate);
71    
72    boolean getViewRealEmail();
73
74    void setViewRealEmail(boolean viewRealEmail);
75    
76    String JavaDoc getPassword();
77    
78    void setPassword(String JavaDoc password);
79    
80    boolean getEnabled();
81    
82    void setEnabled(boolean enable);
83
84    /**
85     * Return the last time the user logged in or null if this date is not known.
86     */

87    Date JavaDoc getLastVisitDate();
88
89    /**
90     * Returns the roles related to this user.
91     */

92    Set JavaDoc getRoles();
93
94    /**
95     * Update the roles.
96     */

97    void setRoles(Set JavaDoc roles);
98
99    /**
100     * Return all the role names of the user.
101     */

102    Set JavaDoc getRoleNames();
103
104    /**
105     * Returns the user properties.
106     */

107    PropertyMap getProperties();
108
109    /**
110     * Returns the user preference store.
111     */

112    PreferenceStore getPreferenceStore();
113
114    /**
115     * Returns the signature of the user (for forums for example)
116     */

117    String JavaDoc getSignature();
118 }
119
Popular Tags