From: Roland Haeder Date: Thu, 17 Sep 2015 06:23:55 +0000 (+0200) Subject: Some fixes + updated jcore.jar X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=893853d012e88c107763ce0f3a81bdda9420fb38;p=jfinancials-swing.git Some fixes + updated jcore.jar Signed-off-by:Roland Häder --- diff --git a/lib/jcore.jar b/lib/jcore.jar index 4426c96..107bb12 100644 Binary files a/lib/jcore.jar and b/lib/jcore.jar differ diff --git a/src/org/mxchange/addressbook/application/AddressbookApplication.java b/src/org/mxchange/addressbook/application/AddressbookApplication.java index 2e16df4..7dbbf57 100644 --- a/src/org/mxchange/addressbook/application/AddressbookApplication.java +++ b/src/org/mxchange/addressbook/application/AddressbookApplication.java @@ -182,6 +182,7 @@ public class AddressbookApplication extends BaseFrameworkSystem implements Appli } else { // Not client choosen this.getLogger().error("No client choosen. Cannot launch."); //NOI18N + try { this.doShutdown(); } catch (final SQLException | IOException ex) { @@ -256,10 +257,10 @@ public class AddressbookApplication extends BaseFrameworkSystem implements Appli public void doShutdown () throws SQLException, IOException { // Trace message this.getLogger().trace("CALLED!"); //NOI18N - + // Shutdown client this.getClient().doShutdown(); - + this.getLogger().info("End of program (last line)"); //NOI18N System.exit(0); } diff --git a/src/org/mxchange/addressbook/client/console/ConsoleClient.java b/src/org/mxchange/addressbook/client/console/ConsoleClient.java index 082e49b..ecfbd4d 100644 --- a/src/org/mxchange/addressbook/client/console/ConsoleClient.java +++ b/src/org/mxchange/addressbook/client/console/ConsoleClient.java @@ -37,6 +37,7 @@ import org.mxchange.jcore.application.Application; import org.mxchange.jcore.exceptions.UnhandledUserChoiceException; import org.mxchange.jcore.model.contact.Contact; import org.mxchange.jcore.model.contact.gender.Gender; +import org.mxchange.jcore.model.contact.gender.GenderUtils; /** * A client for the console @@ -109,7 +110,7 @@ public class ConsoleClient extends BaseAddressbookClient implements AddressbookC } // Get translated gender as the user may want to see "Mr.", "Mrs." - String gender = contact.getTranslatedGender(); + String gender = GenderUtils.getTranslatedGender(contact); // Get company name String companyName = contact.getCompanyName(); diff --git a/src/org/mxchange/addressbook/manager/contact/AddressbookContactManager.java b/src/org/mxchange/addressbook/manager/contact/AddressbookContactManager.java index c7aed6a..65bdd97 100644 --- a/src/org/mxchange/addressbook/manager/contact/AddressbookContactManager.java +++ b/src/org/mxchange/addressbook/manager/contact/AddressbookContactManager.java @@ -710,7 +710,7 @@ public class AddressbookContactManager extends BaseManager implements Manageable // Then iterate over all while (iterator.hasNext()) { // Get next element - String key = iterator.next(); + String key = iterator.next().toLowerCase(); // Does the key start with AddressbookContactManager.columnName ? if (key.startsWith("ContactManager.columnName")) { //NOI18N diff --git a/src/org/mxchange/addressbook/model/contact/book/BookContact.java b/src/org/mxchange/addressbook/model/contact/book/BookContact.java index c34066f..65ef941 100644 --- a/src/org/mxchange/addressbook/model/contact/book/BookContact.java +++ b/src/org/mxchange/addressbook/model/contact/book/BookContact.java @@ -26,6 +26,10 @@ import org.mxchange.jcore.model.contact.Contact; * @version 0.0 */ public class BookContact extends BaseContact implements Contact { + /** + * Serial number + */ + private static final long serialVersionUID = 27_834_738_781L; /** * Default constructor, may only be used from database backend diff --git a/src/org/mxchange/addressbook/model/contact/user/UserContact.java b/src/org/mxchange/addressbook/model/contact/user/UserContact.java index ef51cb4..8642ae1 100644 --- a/src/org/mxchange/addressbook/model/contact/user/UserContact.java +++ b/src/org/mxchange/addressbook/model/contact/user/UserContact.java @@ -27,6 +27,10 @@ import org.mxchange.jcore.model.contact.gender.Gender; * TODO After a Collection has been used in ContactManager, change to BaseContact */ public class UserContact extends BookContact implements Contact { + /** + * Serial number + */ + private static final long serialVersionUID = 36_725_784_819_501L; /** * Creates own contact entry