]> git.mxchange.org Git - addressbook-lib.git/blob - Addressbook/src/org/mxchange/addressbook/manager/contact/ManageableContact.java
the contact manager instance only exists when initFrame() is called and not on object...
[addressbook-lib.git] / Addressbook / src / org / mxchange / addressbook / manager / contact / ManageableContact.java
1 /*\r
2  * Copyright (C) 2015 Roland Haeder\r
3  *\r
4  * This program is free software: you can redistribute it and/or modify\r
5  * it under the terms of the GNU General Public License as published by\r
6  * the Free Software Foundation, either version 3 of the License, or\r
7  * (at your option) any later version.\r
8  *\r
9  * This program is distributed in the hope that it will be useful,\r
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of\r
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\r
12  * GNU General Public License for more details.\r
13  *\r
14  * You should have received a copy of the GNU General Public License\r
15  * along with this program.  If not, see <http://www.gnu.org/licenses/>.\r
16  */\r
17 package org.mxchange.addressbook.manager.contact;\r
18 \r
19 import java.util.List;\r
20 import org.mxchange.addressbook.client.Client;\r
21 import org.mxchange.addressbook.contact.Contact;\r
22 import org.mxchange.addressbook.manager.Manageable;\r
23 \r
24 /**\r
25  *\r
26  * @author Roland Haeder\r
27  */\r
28 public interface ManageableContact extends Manageable {\r
29 \r
30     /**\r
31      * Shuts down this contact manager\r
32      */\r
33     public void doShutdown ();\r
34 \r
35     /**\r
36      * List all contacts\r
37      */\r
38     public void listContacts ();\r
39 \r
40     /**\r
41      * Adds given contact to address book\r
42      *\r
43      * @param contact Contact being added\r
44      * @todo Add check for book size\r
45      */\r
46     public void registerContact (final Contact contact);\r
47 \r
48     /**\r
49      * Adds given Contact instance to list\r
50      * \r
51      * @param contact Contact instance to add\r
52      */\r
53     public void addContact (final Contact contact);\r
54 \r
55     /**\r
56      * Let the user add a new other address\r
57      */\r
58     public void addOtherAddress();\r
59 \r
60     /**\r
61      * The user can change address data, like street, ZIP code, city and country\r
62      * of given Contact instance.\r
63      * \r
64      * @param contact Instance to change data\r
65      * @param client Client instance to call back\r
66      */\r
67     public void doChangeAddressData (final Contact contact, final Client client);\r
68 \r
69     /**\r
70      * The user can change name data, like gender, surname, family name and\r
71      * company name (if business contact).\r
72      * \r
73      * @param contact Instance to change data\r
74      * @param client Client instance to call back\r
75      */\r
76     public void doChangeNameData (final Contact contact, final Client client);\r
77 \r
78     /**\r
79      * Let the user change other address\r
80      */\r
81     public void changeOtherAddress();\r
82 \r
83     /**\r
84      * The user can change other data, like phone numbers or comments.\r
85      * \r
86      * @param contact Instance to change data\r
87      * @param client Client instance to call back\r
88      */\r
89     public void doChangeOtherData (final Contact contact, final Client client);\r
90 \r
91     /**\r
92      * Let the user change own data\r
93      */\r
94     public void changeOwnData();\r
95 \r
96     /**\r
97      * Let the user delete other address\r
98      */\r
99     public void deleteOtherAddress();\r
100 \r
101     /**\r
102      * Asks user for own data\r
103      */\r
104     public void doEnterOwnData();\r
105 \r
106     /**\r
107      * Getter for whole list\r
108      * @return List of all contacts\r
109      */\r
110     public List<Contact> getList ();\r
111 \r
112     /**\r
113      * Searches address book for a contact\r
114      */\r
115     public void searchContacts ();\r
116 \r
117     /**\r
118      * Checks whether own contact is already added by checking all entries for\r
119      * isOwnContact flag\r
120      * \r
121      * @return Whether own contact is already added\r
122      */\r
123     public boolean isOwnContactAdded ();\r
124 \r
125     /**\r
126      * Getter for size\r
127      *\r
128      * @return size of contact "book"\r
129      */\r
130     public int size();\r
131 }\r