]> git.mxchange.org Git - addressbook-swing.git/blob - Addressbook/src/org/mxchange/addressbook/manager/contact/ManageableContact.java
Introduced Gender enum which replaces the old char
[addressbook-swing.git] / Addressbook / src / org / mxchange / addressbook / manager / contact / ManageableContact.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.manager.contact;
18
19 import java.util.List;
20 import org.mxchange.addressbook.client.Client;
21 import org.mxchange.addressbook.contact.Contact;
22 import org.mxchange.addressbook.contact.Gender;
23 import org.mxchange.addressbook.manager.Manageable;
24
25 /**
26  *
27  * @author Roland Haeder
28  */
29 public interface ManageableContact extends Manageable {
30
31         /**
32          * Shuts down this contact manager
33          */
34         public void doShutdown ();
35
36         /**
37          * Allows the user to enter own cellphone number.
38          *
39          * @return Cellphone number
40          */
41         public String enterOwnCellNumber ();
42
43         /**
44          * Allows the user to enter own city name.
45          *
46          * @return City name
47          */
48         public String enterOwnCity ();
49
50         /**
51          * Allows the user to enter comment for own entry.
52          *
53          * @return Comment
54          */
55         public String enterOwnComment ();
56
57         /**
58          * Allows the user to enter own company name.
59          *
60          * @return Company name
61          */
62         public String enterOwnCompanyName ();
63
64         /**
65          * Allows the user to enter own country code.
66          *
67          * @return Country code
68          */
69         public String enterOwnCountryCode ();
70
71         /**
72          * Allows the user to enter own email address.
73          *
74          * @return Email address
75          */
76         public String enterOwnEmailAddress ();
77
78         /**
79          * Allows the user to enter own family name.
80          *
81          * @return Family name
82          */
83         public String enterOwnFamilyName ();
84
85         /**
86          * Allows the user to enter own fax number.
87          *
88          * @return Fax number
89          */
90         public String enterOwnFaxNumber ();
91
92         /**
93          * Allows the user to enter own gender.
94          *
95          * @return Gender
96          */
97         public Gender enterOwnGender ();
98
99         /**
100          * Allows the user to enter own phone number.
101          *
102          * @return Phone number
103          */
104         public String enterOwnPhoneNumber ();
105
106         /**
107          * Allows the user to enter own street and house number.
108          *
109          * @return Street and house number
110          */
111         public String enterOwnStreet ();
112
113         /**
114          * Allows the user to enter own surname.
115          *
116          * @return Surname
117          */
118         public String enterOwnSurname ();
119
120         /**
121          * Allows the user to enter own ZIP code.
122          *
123          * @return ZIP code
124          */
125         public int enterOwnZipCode ();
126
127         /**
128          * Getter for column count
129          *
130          * @return Column count
131          */
132         public int getColumnCount ();
133
134         /**
135          * List all contacts
136          */
137         public void doListContacts ();
138
139         /**
140          * Getter for column name at given index.
141          *
142          * @param columnIndex Column index
143          * @return Human-readable column name
144          */
145         public String getColumnName (final int columnIndex);
146
147         /**
148          * Adds given contact to address book
149          *
150          * @param contact Contact being added
151          * @todo Add check for book size
152          */
153         public void registerContact (final Contact contact);
154
155         /**
156          * Adds given Contact instance to list
157          *
158          * @param contact Contact instance to add
159          */
160         public void addContact (final Contact contact);
161
162         /**
163          * Let the user add a new other address
164          */
165         public void doAddOtherAddress ();
166
167         /**
168          * The user can change address data, like street, ZIP code, city and country
169          * of given Contact instance.
170          *
171          * @param contact Instance to change data
172          * @param client Client instance to call back
173          */
174         public void doChangeAddressData (final Contact contact, final Client client);
175
176         /**
177          * The user can change name data, like gender, surname, family name and
178          * company name (if business contact).
179          *
180          * @param contact Instance to change data
181          * @param client Client instance to call back
182          */
183         public void doChangeNameData (final Contact contact, final Client client);
184
185         /**
186          * Let the user change other address
187          */
188         public void doChangeOtherAddress ();
189
190         /**
191          * The user can change other data, like phone numbers or comments.
192          *
193          * @param contact Instance to change data
194          * @param client Client instance to call back
195          */
196         public void doChangeOtherData (final Contact contact, final Client client);
197
198         /**
199          * Let the user change own data
200          */
201         public void doChangeOwnData ();
202
203         /**
204          * Let the user delete other address
205          */
206         public void doDeleteOtherAddress ();
207
208         /**
209          * Asks user for own data
210          */
211         public void doEnterOwnData ();
212
213         /**
214          * Getter for whole list
215          *
216          * @return List of all contacts
217          */
218         public List<Contact> getList ();
219
220         /**
221          * Searches address book for a contact
222          */
223         public void doSearchContacts ();
224
225         /**
226          * Checks whether own contact is already added by checking all entries for
227          * isOwnContact flag
228          *
229          * @return Whether own contact is already added
230          */
231         public boolean isOwnContactAdded ();
232
233         /**
234          * Getter for size
235          *
236          * @return size of contact "book"
237          */
238         public int size ();
239 }