]> git.mxchange.org Git - addressbook-war.git/blob - src/java/org/mxchange/addressbook/beans/user/UserWebController.java
f5df38c9246df8707e8416d55e02e2dc64b587f5
[addressbook-war.git] / src / java / org / mxchange / addressbook / beans / user / UserWebController.java
1 /*
2  * Copyright (C) 2015 Roland Haeder
3  *
4  * This program is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation, either version 3 of the License, or
7  * (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
16  */
17 package org.mxchange.addressbook.beans.user;
18
19 import java.io.Serializable;
20 import java.util.Date;
21 import org.mxchange.jcontacts.contact.gender.Gender;
22 import org.mxchange.jcountry.data.Country;
23 import org.mxchange.jphone.phonenumbers.smsprovider.SmsProvider;
24 import org.mxchange.jusercore.model.user.User;
25
26 /**
27  * An interface for user beans
28  * <p>
29  * @author Roland Haeder<roland@mxchange.org>
30  */
31 public interface UserWebController extends Serializable {
32
33         /**
34          * Adds user's name and email address to bean's internal list
35          * <p>
36          * @param user User instance
37          */
38         public void addUserNameEmailAddress (final User user);
39
40         /**
41          * Clears all data in this bean
42          */
43         public void clearData ();
44
45         /**
46          * Copies given user into the controller
47          * <p>
48          * @param user User instance
49          */
50         public void copyUser (final User user);
51
52         /**
53          * Creates an instance from all properties
54          * <p>
55          * @return A user instance
56          */
57         public User createUserInstance ();
58
59         /**
60          * Getter for birth day
61          * <p>
62          * @return Birth day
63          */
64         public Date getBirthday ();
65
66         /**
67          * Setter for birth day
68          * <p>
69          * @param birthday Birth day
70          */
71         public void setBirthday (final Date birthday);
72
73         /**
74          * Getter for ellphone number's carrier
75          * <p>
76          * @return Cellphone number's carrier
77          */
78         public SmsProvider getCellphoneCarrier ();
79
80         /**
81          * Setter for cellphone number's carrier prefix
82          * <p>
83          * @param cellphoneCarrier Cellphone number's carrier prefix
84          */
85         public void setCellphoneCarrier (final SmsProvider cellphoneCarrier);
86
87         /**
88          * Getter for ellphone number
89          * <p>
90          * @return Cellphone number
91          */
92         public Long getCellphoneNumber ();
93
94         /**
95          * Setter for ellphone number
96          * <p>
97          * @param cellphoneNumber Cellphone number
98          */
99         public void setCellphoneNumber (final Long cellphoneNumber);
100
101         /**
102          * City
103          * <p>
104          * @return the city
105          */
106         public String getCity ();
107
108         /**
109          * City
110          * <p>
111          * @param city the city to set
112          */
113         public void setCity (final String city);
114
115         /**
116          * Getter for comments
117          * <p>
118          * @return Comments
119          */
120         public String getComment ();
121
122         /**
123          * Setter for comment
124          * <p>
125          * @param comment Comments
126          */
127         public void setComment (final String comment);
128
129         /**
130          * Getter for country instance
131          * <p>
132          * @return Country instance
133          */
134         public Country getCountry ();
135
136         /**
137          * Setter for country instance
138          * <p>
139          * @param country Country instance
140          */
141         public void setCountry (final Country country);
142
143         /**
144          * Getter for email address
145          * <p>
146          * @return Email address
147          */
148         public String getEmailAddress ();
149
150         /**
151          * Setter for email address
152          * <p>
153          * @param emailAddress Email address
154          */
155         public void setEmailAddress (final String emailAddress);
156
157         /**
158          * Getter for email address, repeated
159          * <p>
160          * @return the emailAddress, repeated
161          */
162         public String getEmailAddressRepeat ();
163
164         /**
165          * Setter for email address repeated
166          * <p>
167          * @param emailAddressRepeat the emailAddress to set
168          */
169         public void setEmailAddressRepeat (final String emailAddressRepeat);
170
171         /**
172          * Family name
173          * <p>
174          * @return the familyName
175          */
176         public String getFamilyName ();
177
178         /**
179          * Family name
180          * <p>
181          * @param familyName the familyName to set
182          */
183         public void setFamilyName (final String familyName);
184
185         /**
186          * Getter for fax number's area code
187          * <p>
188          * @return Fax number's area code
189          */
190         public Integer getFaxAreaCode ();
191
192         /**
193          * Setter for fax number's area code
194          * <p>
195          * @param faxAreaCode Fax number's area code
196          */
197         public void setFaxAreaCode (final Integer faxAreaCode);
198
199         /**
200          * Getter for fax's country instance
201          * <p>
202          * @return Fax' country instance
203          */
204         public Country getFaxCountry ();
205
206         /**
207          * Setter for fax's country instance
208          * <p>
209          * @param faxCountry Fax' country instance
210          */
211         public void setFaxCountry (final Country faxCountry);
212
213         /**
214          * Getter for fax number
215          * <p>
216          * @return Fax number
217          */
218         public Long getFaxNumber ();
219
220         /**
221          * Setter for fax number
222          * <p>
223          * @param faxNumber Fax number
224          */
225         public void setFaxNumber (final Long faxNumber);
226
227         /**
228          * First name
229          * <p>
230          * @return the first name
231          */
232         public String getFirstName ();
233
234         /**
235          * First name
236          * <p>
237          * @param firstName the first name to set
238          */
239         public void setFirstName (final String firstName);
240
241         /**
242          * Gender of the contact
243          * <p>
244          * @return the gender
245          */
246         public Gender getGender ();
247
248         /**
249          * Gender of the contact
250          * <p>
251          * @param gender the gender to set
252          */
253         public void setGender (final Gender gender);
254
255         /**
256          * House number
257          * <p>
258          * @return the houseNumber
259          */
260         public Short getHouseNumber ();
261
262         /**
263          * House number
264          * <p>
265          * @param houseNumber the houseNumber to set
266          */
267         public void setHouseNumber (final Short houseNumber);
268
269         /**
270          * Getter for phone number's area code
271          * <p>
272          * @return Phone number's area code
273          */
274         public Integer getPhoneAreaCode ();
275
276         /**
277          * Setter for phone number's area code
278          * <p>
279          * @param phoneAreaCode Phone number's area code
280          */
281         public void setPhoneAreaCode (final Integer phoneAreaCode);
282
283         /**
284          * Getter for phone number's country instance
285          * <p>
286          * @return Phone number's country instance
287          */
288         public Country getPhoneCountry ();
289
290         /**
291          * Setter for phone number's country instance
292          * <p>
293          * @param phoneCountry Phone number's country instance
294          */
295         public void setPhoneCountry (final Country phoneCountry);
296
297         /**
298          * Getter for phone number
299          * <p>
300          * @return Phone number
301          */
302         public Long getPhoneNumber ();
303
304         /**
305          * Setter for phone number
306          * <p>
307          * @param phoneNumber Phone number
308          */
309         public void setPhoneNumber (final Long phoneNumber);
310
311         /**
312          * Street
313          * <p>
314          * @return the street
315          */
316         public String getStreet ();
317
318         /**
319          * Street
320          * <p>
321          * @param street the street to set
322          */
323         public void setStreet (final String street);
324
325         /**
326          * Getter for user id
327          * <p>
328          * @return User id
329          */
330         public Long getUserId ();
331
332         /**
333          * Setter for user id
334          * <p>
335          * @param userId User id
336          */
337         public void setUserId (final Long userId);
338
339         /**
340          * Getter for user name
341          * <p>
342          * @return User name
343          */
344         public String getUserName ();
345
346         /**
347          * Setter for user name
348          * <p>
349          * @param userName User name
350          */
351         public void setUserName (final String userName);
352
353         /**
354          * Getter for unencrypted user password
355          * <p>
356          * @return Unencrypted user password
357          */
358         public String getUserPassword ();
359
360         /**
361          * Setter for unencrypted user password
362          * <p>
363          * @param userPassword Unencrypted user password
364          */
365         public void setUserPassword (final String userPassword);
366
367         /**
368          * Getter for unencrypted user password repeated
369          * <p>
370          * @return Unencrypted user password repeated
371          */
372         public String getUserPasswordRepeat ();
373
374         /**
375          * Setter for unencrypted user password repeated
376          * <p>
377          * @param userPasswordRepeat Unencrypted user password repeated
378          */
379         public void setUserPasswordRepeat (final String userPasswordRepeat);
380
381         /**
382          * ZIP code
383          * <p>
384          * @return the zipCode
385          */
386         public Integer getZipCode ();
387
388         /**
389          * ZIP code
390          * <p>
391          * @param zipCode the zipCode to set
392          */
393         public void setZipCode (final Integer zipCode);
394
395         /**
396          * Checks whether user instance's email address is used
397          * <p>
398          * @param user User instance's email address to check
399          * <p>
400          * @return Whether it is already used
401          */
402         public boolean isEmailAddressRegistered (final User user);
403
404         /**
405          * Checks whether all required personal data is set
406          * <p>
407          * @return Whether the required personal data is set
408          */
409         public boolean isRequiredPersonalDataSet ();
410
411         /**
412          * Checks whether same email addresses have been entered
413          * <p>
414          * @return Whether same email addresses have been entered
415          */
416         public boolean isSameEmailAddressEntered ();
417
418         /**
419          * Checks whether same passwords has been entered
420          * <p>
421          * @return Whether same passwords has been entered
422          */
423         public boolean isSamePasswordEntered ();
424
425         /**
426          * Checks whether given user instance's name is used
427          * <p>
428          * @param user User instance's name to check
429          * <p>
430          * @return Whether it is already used
431          */
432         public boolean isUserNameRegistered (final User user);
433
434         /**
435          * Checks whether a public user account is registered. This means that at
436          * least one user profile has its flag "public user profile" enabled.
437          * <p>
438          * @return Whether at least one user has a public profile
439          */
440         public boolean isPublicUserRegistered ();
441 }