]> git.mxchange.org Git - addressbook-lib.git/commitdiff
Renamed surname to first name + updated jcore.jar
authorRoland Haeder <roland@mxchange.org>
Thu, 20 Aug 2015 11:54:05 +0000 (13:54 +0200)
committerRoland Haeder <roland@mxchange.org>
Thu, 20 Aug 2015 12:22:28 +0000 (14:22 +0200)
Signed-off-by:Roland Häder <roland@mxchange.org>

lib/jcore.jar
src/org/mxchange/addressbook/client/console/ConsoleClient.java
src/org/mxchange/addressbook/contact/user/UserContact.java
src/org/mxchange/addressbook/exceptions/ContactAlreadyAddedException.java
src/org/mxchange/addressbook/manager/contact/AddressbookContactManager.java
src/org/mxchange/addressbook/manager/contact/ManageableAddressbookContact.java

index 7ad4d6ddbbeb94968781b5f967b48c9c6a0cd651..f4f6a200f1248dbeab9edb32638ff954da5ab5a7 100644 (file)
Binary files a/lib/jcore.jar and b/lib/jcore.jar differ
index 6ed15fb2a04a79feee994d412fdfc53bbc388a1c..a9c81cbf6fe60756c42a400ea5348dfdf920e126 100644 (file)
@@ -119,10 +119,10 @@ public class ConsoleClient extends BaseAddressbookClient implements AddressbookC
                if ((companyName == null) || (companyName.isEmpty())) {
                        // Now put all together: gender, surname, family name
                        // @todo Use mask
-                       this.outputMessage(MessageFormat.format("Anrede, Vorname, Name: {0} {1} {2}", gender, contact.getSurname(), contact.getFamilyName()));
+                       this.outputMessage(MessageFormat.format("Anrede, Vorname, Name: {0} {1} {2}", gender, contact.getFirstName(), contact.getFamilyName()));
                } else {
                        // Company contact
-                       this.outputMessage(MessageFormat.format("Firma: {0}\nAnsprechpartner: {1} {2} {3}", companyName, gender, contact.getSurname(), contact.getFamilyName()));
+                       this.outputMessage(MessageFormat.format("Firma: {0}\nAnsprechpartner: {1} {2} {3}", companyName, gender, contact.getFirstName(), contact.getFamilyName()));
                }
 
                // Trace message
@@ -218,7 +218,7 @@ public class ConsoleClient extends BaseAddressbookClient implements AddressbookC
                Gender gender = manager.enterOwnGender();
 
                // Surname
-               String surname = manager.enterOwnSurname();
+               String firstName = manager.enterOwnFirstName();
 
                // Family name
                String familyName = manager.enterOwnFamilyName();
@@ -228,7 +228,7 @@ public class ConsoleClient extends BaseAddressbookClient implements AddressbookC
 
                // Update contact instance
                contact.setGender(gender);
-               contact.setSurname(surname);
+               contact.setFirstName(firstName);
                contact.setFamilyName(familyName);
                contact.setCompanyName(companyName);
 
@@ -294,7 +294,7 @@ public class ConsoleClient extends BaseAddressbookClient implements AddressbookC
                Gender gender = manager.enterOwnGender();
 
                // 2nd for surname
-               String surname = manager.enterOwnSurname();
+               String surname = manager.enterOwnFirstName();
 
                // And 3rd for family name
                String familyName = manager.enterOwnFamilyName();
index 1ca7f8968a6595300050437ad2d77d0c4e648dad..0b7af77b228d070e95ab728589acb5fc67f8a7d2 100644 (file)
@@ -33,21 +33,21 @@ public class UserContact extends BookContact implements Contact {
         * Creates own contact entry
         *
         * @param gender Gender to be set
-        * @param surname Surname to be set
+        * @param firstName First name to be set
         * @param familyName Family name to be set
         * @param companyName Company name
         * @todo Add validation of data
         */
-       public UserContact (final Gender gender, final String surname, final String familyName, final String companyName) {
+       public UserContact (final Gender gender, final String firstName, final String familyName, final String companyName) {
                // Make sure all constructors are called
                this();
 
                // Trace message
-               this.getLogger().trace(MessageFormat.format("gender={0},surname={1},familyName={2},companyName={3} - CALLED!", gender, surname, familyName, companyName)); //NOI18N
+               this.getLogger().trace(MessageFormat.format("gender={0},firstName={1},familyName={2},companyName={3} - CALLED!", gender, firstName, familyName, companyName)); //NOI18N
 
                // Update all data
                this.setGender(gender);
-               this.setSurname(surname);
+               this.setFirstName(firstName);
                this.setFamilyName(familyName);
                this.setCompanyName(companyName);
 
index 634f4b4d08bdfc747491a6a91087cab96fb8ec5f..fa6ac123dcea0af35d333dccc6d6538e272e762d 100644 (file)
@@ -32,7 +32,7 @@ public class ContactAlreadyAddedException extends Exception {
         * @param contact Contact that is already added
         */
        public ContactAlreadyAddedException (final Contact contact) {
-               super(MessageFormat.format("Contact with gender={0}, surname={1} and familyName={2} already added.", contact.getGender(), contact.getSurname(), contact.getFamilyName()));
+               super(MessageFormat.format("Contact with gender={0}, firstName={1} and familyName={2} already added.", contact.getGender(), contact.getFirstName(), contact.getFamilyName()));
        }
 
        /**
index ef41687e2e5b888910d324ae56a33ca77fcc6956..3def29dbe88ca96c29afc94f223591d81a3bf097 100644 (file)
@@ -531,7 +531,7 @@ public class AddressbookContactManager extends BaseManager implements Manageable
         * @return Surname of the user
         */
        @Override
-       public String enterOwnSurname () {
+       public String enterOwnFirstName () {
                // Trace message
                this.getLogger().trace("CALLED!"); //NOI18N
 
@@ -685,7 +685,7 @@ public class AddressbookContactManager extends BaseManager implements Manageable
                }
 
                // Debug message
-               /* NOISY-DEBUG: */ this.getLogger().debug(MessageFormat.format("Adding '{0}' '{1}' at pos '{2}' ...", contact.getSurname(), contact.getFamilyName(), this.size())); //NOI18N
+               /* NOISY-DEBUG: */ this.getLogger().debug(MessageFormat.format("Adding '{0}' '{1}' at pos '{2}' ...", contact.getFirstName(), contact.getFamilyName(), this.size())); //NOI18N
                try {
                        // Check if contact is found
                        if (this.getContactDatabase().isContactFound(contact)) {
index 77d39d35fca1cf335f2a07e7d1d53073eeb2f917..be13daa29141517f09377228711d0aa857e8d941 100644 (file)
@@ -110,7 +110,7 @@ public interface ManageableAddressbookContact extends ManageableDatabase {
         *
         * @return Surname
         */
-       public String enterOwnSurname ();
+       public String enterOwnFirstName ();
 
        /**
         * Allows the user to enter own ZIP code.