KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > edu > rice > rubis > beans > UserLocal


1 package edu.rice.rubis.beans;
2
3 import javax.ejb.*;
4 import java.rmi.*;
5
6 /**
7  * This is the Remote Interface of the User Bean.
8  * @author <a HREF="mailto:">Emmanuel Cecchet</a>
9  * @version 1.0
10  */

11 public interface UserLocal extends EJBLocalObject {
12   /**
13    * Get user's id.
14    *
15    * @return user id
16    */

17   public Integer JavaDoc getId();
18
19   /**
20    * Get user first name.
21    *
22    * @return user first name
23    */

24   public String JavaDoc getFirstName();
25
26   /**
27    * Get user last name.
28    *
29    * @return user last name
30    */

31   public String JavaDoc getLastName();
32
33   /**
34    * Get user nick name. This name is unique for each user and is used for login.
35    *
36    * @return user nick name
37    */

38   public String JavaDoc getNickName();
39
40   /**
41    * Get user password.
42    *
43    * @return user password
44    */

45   public String JavaDoc getPassword();
46
47   /**
48    * Get user email address.
49    *
50    * @return user email address
51    */

52   public String JavaDoc getEmail();
53   
54   /**
55    * Get user rating. The higher the rating is, the most reliable the user is.
56    *
57    * @return user rating
58    */

59   public int getRating();
60   
61   /**
62    * Get user's account current balance. This account is used when a user want to sell items.
63    * There is a charge for each item to sell.
64    *
65    * @return user's account current balance
66    */

67   public float getBalance();
68
69   /**
70    * Get user creation date.
71    *
72    * @return user creation date
73    */

74   public String JavaDoc getCreationDate();
75   
76   /**
77    * Get region identifier of user's region.
78    *
79    * @return region id of the user
80    */

81   public Integer JavaDoc getRegionId();
82     
83
84   /**
85    * Set user's first name
86    *
87    * @param newName user first name
88    */

89   public void setFirstName(String JavaDoc newName);
90
91   /**
92    * Set user's last name
93    *
94    * @param newName user last name
95    */

96   public void setLastName(String JavaDoc newName);
97
98   /**
99    * Set user's nick name
100    *
101    * @param newName user nick name
102    */

103   public void setNickName(String JavaDoc newName);
104
105   /**
106    * Set user's password
107    *
108    * @param newPassword a <code>String</code> value
109    */

110   public void setPassword(String JavaDoc newPassword);
111
112   /**
113    * Set user's email address
114    *
115    * @param newEmail a <code>String</code> value
116    */

117   public void setEmail(String JavaDoc newEmail);
118
119   /**
120    * Set a new creation date for this user account
121    *
122    * @param newCreationDate new user account creation date
123    */

124   public void setCreationDate(String JavaDoc newCreationDate);
125
126   /**
127    * Set a new region identifier. This id must match
128    * the primary key of the region table.
129    *
130    * @param id region id
131    */

132   public void setRegionId(Integer JavaDoc id);
133
134   /**
135    * Set user rating. The higher the rating is, the most reliable the user is.
136    *
137    * @param newRating new user rating
138    */

139   public void setRating(int newRating);
140
141   /**
142    * Update the current rating by adding a new value to it. This value can
143    * be negative if someone wants to decrease the user rating.
144    *
145    * @param diff value to add to the rating
146    */

147   public void updateRating(int diff);
148   
149   /**
150    * Set user's account current balance. This account is used when a user want to sell items.
151    * There is a charge for each sold item.
152    *
153    * @param newBalance set user's account current balance
154    */

155   public void setBalance(float newBalance);
156
157
158   /**
159    * Returns a string displaying general information about the user.
160    * The string contains HTML tags.
161    *
162    * @return string containing general user information
163    */

164   public String JavaDoc getHTMLGeneralUserInformation();
165 }
166
Popular Tags