]> git.mxchange.org Git - jbonuscard-lib.git/commitdiff
Added more thrown exceptions
authorRoland Haeder <roland@mxchange.org>
Wed, 12 Aug 2015 18:10:46 +0000 (20:10 +0200)
committerRoland Haeder <roland@mxchange.org>
Wed, 12 Aug 2015 18:10:46 +0000 (20:10 +0200)
Signed-off-by:Roland Häder <roland@mxchange.org>

Addressbook/src/org/mxchange/addressbook/application/AddressbookApplication.java
Addressbook/src/org/mxchange/addressbook/client/console/ConsoleClient.java
Addressbook/src/org/mxchange/addressbook/client/gui/SwingClient.java

index ea26bc1ec1bbe7117f389c6c3a2a0fcd9254202d..e4ac7a9f6b15b3fb6d406cd4173d0d622a1feb86 100644 (file)
@@ -17,6 +17,7 @@
 package org.mxchange.addressbook.application;
 
 import java.io.IOException;
+import java.sql.SQLException;
 import java.text.MessageFormat;
 import org.mxchange.addressbook.BaseAddressbookSystem;
 import org.mxchange.addressbook.client.AddressbookClient;
@@ -241,7 +242,7 @@ public class AddressbookApplication extends BaseAddressbookSystem implements App
         * Shuts down the application.
         */
        @Override
-       public void doShutdown () {
+       public void doShutdown () throws SQLException, IOException {
                // Trace message
                this.getLogger().trace("CALLED!"); //NOI18N
                
@@ -346,7 +347,11 @@ public class AddressbookApplication extends BaseAddressbookSystem implements App
 
                // Good bye, but this should not be reached ...
                this.getLogger().warn("Unusual exit reached."); //NOI18N
-               this.doShutdown();
+               try {
+                       this.doShutdown();
+               } catch (final SQLException | IOException ex) {
+                       this.abortProgramWithException(ex);
+               }
        }
 
        /**
index 176418b4f38849891d7cf7936bf4a40a467dff13..04f70379db31f321e8694349d84e03f83ce46861 100644 (file)
@@ -16,6 +16,7 @@
  */
 package org.mxchange.addressbook.client.console;
 
+import java.io.IOException;
 import java.sql.SQLException;
 import java.text.MessageFormat;
 import java.util.Arrays;
@@ -314,7 +315,7 @@ public class ConsoleClient extends BaseAddressbookClient implements AddressbookC
         * Shutdown this client
         */
        @Override
-       public void doShutdown () {
+       public void doShutdown () throws SQLException, IOException {
                // Trace message
                this.getLogger().trace("CALLED!"); //NOI18N
 
index 8a27f24c3d6e3f01ed730c41119f8f2e950f24ca..2ad4ae2d7e663d9dc103402ce49ac1ded43fa870 100644 (file)
@@ -16,6 +16,7 @@
  */
 package org.mxchange.addressbook.client.gui;
 
+import java.io.IOException;
 import java.sql.SQLException;
 import org.mxchange.addressbook.client.AddressbookClient;
 import org.mxchange.addressbook.client.BaseAddressbookClient;
@@ -107,7 +108,7 @@ public class SwingClient extends BaseAddressbookClient implements AddressbookCli
         * Shuts down this client
         */
        @Override
-       public void doShutdown () {
+       public void doShutdown () throws SQLException, IOException {
                // Debug message
                this.getLogger().trace("CALLED!"); //NOI18N