]> git.mxchange.org Git - pizzaservice-war.git/blob - src/java/org/mxchange/pizzaapplication/beans/user/password/PizzaUserPasswordWebRequestController.java
Please cherry-pick:
[pizzaservice-war.git] / src / java / org / mxchange / pizzaapplication / beans / user / password / PizzaUserPasswordWebRequestController.java
1 /*
2  * Copyright (C) 2016, 2017 Roland Häder
3  *
4  * This program is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU Affero General Public License as
6  * published by the Free Software Foundation, either version 3 of the
7  * License, or (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 Affero General Public License for more details.
13  *
14  * You should have received a copy of the GNU Affero General Public License
15  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
16  */
17 package org.mxchange.pizzaapplication.beans.user.password;
18
19 import java.io.Serializable;
20 import javax.ejb.Local;
21
22 /**
23  * An interface for user beans
24  * <p>
25  * @author Roland Häder<roland@mxchange.org>
26  */
27 @Local
28 public interface PizzaUserPasswordWebRequestController extends Serializable {
29
30         /**
31          * Getter for clear-text user password
32          * <p>
33          * @return Clear-text user password
34          */
35         String getUserPassword ();
36
37         /**
38          * Setter for clear-text user password
39          * <p>
40          * @param userPassword Clear-text user password
41          */
42         void setUserPassword (final String userPassword);
43
44         /**
45          * Getter for current clear-text user password
46          * <p>
47          * @return Current clear-text user password
48          */
49         String getUserCurrentPassword ();
50
51         /**
52          * Setter for current clear-text user password
53          * <p>
54          * @param userCurrentPassword Current clear-text user password
55          */
56         void setUserCurrentPassword (final String userCurrentPassword);
57
58         /**
59          * Getter for clear-text user password repeated
60          * <p>
61          * @return Clear-text user password repeated
62          */
63         String getUserPasswordRepeat ();
64
65         /**
66          * Setter for clear-text user password repeated
67          * <p>
68          * @param userPasswordRepeat Clear-text user password repeated
69          */
70         void setUserPasswordRepeat (final String userPasswordRepeat);
71
72         /**
73          * Changes logged-in user's password. It must not match with current
74          * password and should not appear in password history list for X
75          * (configurable) entries.
76          * <p>
77          * @return Redirect outcome
78          */
79         String doChangePassword ();
80
81         /**
82          * Checks if all 3 passwords are set: old password, 2x new password
83          * <p>
84          * @return Whether all passwords are set
85          */
86         boolean isRequiredChangePasswordSet ();
87
88 }