]> git.mxchange.org Git - addressbook-swing.git/blobdiff - src/org/mxchange/addressbook/facade/contact/AddressbookContactFacade.java
using gender for Mr./Mrs. is plain wrong, now "personal title" and "academic
[addressbook-swing.git] / src / org / mxchange / addressbook / facade / contact / AddressbookContactFacade.java
index ffb36ca5125ddaa254857fb9cbfc8d488866481a..74d3653cc1d83676246004085a41a78e0cec8eb0 100644 (file)
@@ -25,8 +25,8 @@ import java.util.Iterator;
 import java.util.List;
 import org.mxchange.addressbook.client.AddressbookClient;
 import org.mxchange.jcontacts.contact.Contact;
-import org.mxchange.jcontacts.contact.gender.Gender;
-import org.mxchange.jcontacts.exceptions.ContactAlreadyAddedException;
+import org.mxchange.jcontacts.contact.title.PersonalTitle;
+import org.mxchange.jcontactsbusiness.exceptions.BusinessContactAlreadyAddedException;
 import org.mxchange.jcore.client.Client;
 import org.mxchange.jcore.exceptions.UnhandledUserChoiceException;
 import org.mxchange.jcore.facade.BaseFacade;
@@ -94,7 +94,7 @@ public class AddressbookContactFacade extends BaseFacade implements ContactFacad
        }
 
        @Override
-       public void addContact (final Contact contact) throws ContactAlreadyAddedException {
+       public void addContact (final Contact contact) throws BusinessContactAlreadyAddedException {
                // Trace message
                this.getLoggerBeanLocal().logTrace(MessageFormat.format("contact={0} - CALLED!", contact)); //NOI18N
 
@@ -261,14 +261,14 @@ public class AddressbookContactFacade extends BaseFacade implements ContactFacad
        }
 
        @Override
-       public void doEnterOwnData () throws ContactAlreadyAddedException {
+       public void doEnterOwnData () throws BusinessContactAlreadyAddedException {
                // Trace message
                this.getLoggerBeanLocal().logTrace("CALLED!"); //NOI18N
 
                // Is own contact already added?
                if (this.isOwnContactAdded()) {
                        // Don't continue here
-                       throw new ContactAlreadyAddedException();
+                       throw new BusinessContactAlreadyAddedException();
                }
 
                // Get and cast client instance
@@ -409,14 +409,14 @@ public class AddressbookContactFacade extends BaseFacade implements ContactFacad
        }
 
        @Override
-       public Gender enterOwnGender () {
+       public PersonalTitle enterOwnPersonalTitle () {
                // Trace message
                this.getLoggerBeanLocal().logTrace("CALLED!"); //NOI18N
 
                // Get and cast client instance
                AddressbookClient client = (AddressbookClient) this.getClient();
 
-               return client.enterGender("Bitte geben Sie die Anrede ein: (M=Herr, F=Frau, C=Firma): ");
+               return client.enterPersonalTitle("Bitte geben Sie die Anrede ein: (M=Herr, F=Frau, C=Firma): ");
        }
 
        @Override
@@ -533,7 +533,7 @@ public class AddressbookContactFacade extends BaseFacade implements ContactFacad
 
                        // Add contact to internal list
                        this.addContact(contact);
-               } catch (final ContactAlreadyAddedException ex) {
+               } catch (final BusinessContactAlreadyAddedException ex) {
                        // Abort here
                        this.abortProgramWithException(ex);
                }