]> git.mxchange.org Git - addressbook-war.git/blob - src/java/org/mxchange/addressbook/beans/addressbook/AddressbookWebController.java
Rewrite:
[addressbook-war.git] / src / java / org / mxchange / addressbook / beans / addressbook / AddressbookWebController.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.addressbook;
18
19 import java.io.Serializable;
20
21 /**
22  * An interface for user beans
23  * <p>
24  * @author Roland Haeder<roland@mxchange.org>
25  */
26 public interface AddressbookWebController extends Serializable {
27
28         /**
29          * Checks whether the user has created addressbooks. For this method to work
30          * it is vital that the user is logged into his/her account.
31          * <p>
32          * @return Whether the user has created at least one addressbook
33          */
34         public boolean hasCreatedAddressbooks ();
35
36         /**
37          * Creates a new address book with a name. For this method to work it is
38          * vital that the user is logged into his/her account.
39          */
40         public void addAddressbook ();
41
42         /**
43          * Getter for address book name
44          * <p>
45          * @return Address book name
46          */
47         public String getAddressbookName ();
48
49         /**
50          * Setter for address book name
51          * <p>
52          * @param addressbookName Address book name
53          */
54         public void setAddressbookName (final String addressbookName);
55
56         /**
57          * Checks if the given address book name is already used by the user.
58          * <p>
59          * @param addressbookName Address book name to check
60          * <p>
61          * @return Whether the name has already been used by the user
62          */
63         public boolean isAddressbookNameUsed (final String addressbookName);
64 }