]> git.mxchange.org Git - pizzaservice-core.git/commitdiff
More no longer used methods removed (they were needed for the TDGP) and more cleanups.
authorRoland Haeder <roland@mxchange.org>
Fri, 4 Sep 2015 17:02:53 +0000 (19:02 +0200)
committerRoland Haeder <roland@mxchange.org>
Fri, 4 Sep 2015 17:02:53 +0000 (19:02 +0200)
Signed-off-by:Roland Häder <roland@mxchange.org>

PizzaService-ejb/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaBean.java
PizzaService-ejb/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaServiceBean.java
PizzaService-ejb/src/java/org/mxchange/pizzaapplication/beans/customer/ShopCustomerSessionBean.java
PizzaService-ejb/src/java/org/mxchange/pizzaapplication/beans/pizzaservice/PizzaServiceSessionBean.java
PizzaService-ejb/src/java/org/mxchange/pizzaapplication/tags/basket/MiniBasketTag.java

index 8fb5b2d5c07583ed8835838ac5f247c31ab91471..9a09d69d89b25a38d09f90a9f72ee5540dd1692b 100644 (file)
@@ -21,9 +21,9 @@ import java.util.Deque;
 import java.util.Iterator;
 import javax.faces.FacesException;
 import org.mxchange.jshop.beans.FrameworkBean;
-import org.mxchange.jshop.category.Category;
-import org.mxchange.jshop.item.AddableBasketItem;
-import org.mxchange.jshop.product.Product;
+import org.mxchange.jshop.model.category.Category;
+import org.mxchange.jshop.model.item.AddableBasketItem;
+import org.mxchange.jshop.model.product.Product;
 
 /**
  *
index 369b1b9f22d4d1722fd528bb97409f376a1b6e0f..84c138360dbe813a6c20ee63de602f17cf0197e9 100644 (file)
@@ -24,15 +24,12 @@ import java.util.Deque;
 import java.util.Iterator;
 import javax.annotation.PostConstruct;
 import javax.ejb.Stateless;
-import org.mxchange.jcore.exceptions.BadTokenException;
-import org.mxchange.jcore.exceptions.CorruptedDatabaseFileException;
-import org.mxchange.jcore.exceptions.UnsupportedDatabaseBackendException;
 import org.mxchange.jshop.beans.BaseFrameworkBean;
-import org.mxchange.jshop.category.Category;
 import org.mxchange.jshop.exceptions.CategoryTitleAlreadyUsedException;
 import org.mxchange.jshop.exceptions.ProductTitleAlreadyUsedException;
-import org.mxchange.jshop.item.AddableBasketItem;
-import org.mxchange.jshop.product.Product;
+import org.mxchange.jshop.model.category.Category;
+import org.mxchange.jshop.model.item.AddableBasketItem;
+import org.mxchange.jshop.model.product.Product;
 import org.mxchange.pizzaapplication.application.PizzaApplication;
 import org.mxchange.pizzaapplication.application.PizzaServiceApplication;
 
@@ -78,7 +75,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
                try {
                        // Call init method
                        this.app.init();
-               } catch (final UnsupportedDatabaseBackendException | SQLException | IOException | BadTokenException ex) {
+               } catch (final SQLException | IOException ex) {
                        // Continue to throw
                        throw new RuntimeException(ex);
                }
@@ -94,7 +91,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public Iterator<Product> getAvailableProductsIterator () throws RemoteException {
                try {
                        return this.app.getAvailableProductsIterator();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("getAvailableProductsIterator() failed.", ex);
                }
@@ -104,7 +101,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public Iterator<Product> getAllProductsIterator () throws RemoteException {
                try {
                        return this.app.getAllProductsIterator();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("getAllProductsIterator() failed.", ex);
                }
@@ -114,7 +111,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public Deque<Product> getAvailableProducts () throws RemoteException {
                try {
                        return this.app.getAvailableProducts();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("getAvailableProducts() failed.", ex);
                }
@@ -124,7 +121,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public Deque<Product> getAllProducts () throws RemoteException {
                try {
                        return this.app.getAllProducts();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("getAllProducts() failed.", ex);
                }
@@ -134,7 +131,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public Iterator<Category> getAllCategoriesIterator () throws RemoteException {
                try {
                        return this.app.getAllCategoriesIterator();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("getAllCategoriesIterator() failed.", ex);
                }
@@ -144,7 +141,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public Deque<Category> getAllCategories () throws RemoteException {
                try {
                        return this.app.getAllCategories();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("getAllCategories() failed.", ex);
                }
@@ -154,7 +151,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public void doAdminAddCategory (final Category category) throws RemoteException {
                try {
                        this.app.doAdminAddCategory(category);
-               } catch (final CategoryTitleAlreadyUsedException | IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final CategoryTitleAlreadyUsedException | IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("doAdminAddCategory() failed.", ex);
                }
@@ -164,7 +161,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public void doAdminAddProduct (final Product product) throws RemoteException {
                try {
                        this.app.doAdminAddProduct(product);
-               } catch (final ProductTitleAlreadyUsedException | IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final ProductTitleAlreadyUsedException | IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("doAdminAddProduct() failed.", ex);
                }
@@ -175,7 +172,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public String getPrintableProduktCategory (final Product product) throws RemoteException {
                try {
                        return this.app.getPrintableProductCategory(product);
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("getPrintableProduktCategory() failed.", ex);
                }
@@ -186,7 +183,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public void doAdminHandleProductForms () throws RemoteException {
                try {
                        this.app.doAdminHandleProductForms();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException | ProductTitleAlreadyUsedException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException | ProductTitleAlreadyUsedException ex) {
                        // Continue to throw
                        throw new RemoteException("doAdminHandleProductForms() failed.", ex);
                }
@@ -197,7 +194,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
        public void doAdminHandleCategoryForms () throws RemoteException {
                try {
                        this.app.doAdminHandleCategoryForms();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException | CategoryTitleAlreadyUsedException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException | CategoryTitleAlreadyUsedException ex) {
                        // Continue to throw
                        throw new RemoteException("doAdminHandleCategoryForms() failed.", ex);
                }
@@ -208,7 +205,7 @@ public class PizzaServiceBean extends BaseFrameworkBean implements PizzaBean {
                try {
                        // Deligate to application
                        return this.app.getProduct(item);
-               } catch (IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new RemoteException("getProduct() failed.", ex);
                }
index 7ec4c77ce4025619014e36b4df0e6a3c68285d66..5eee244b1b3e59c014ebc2d72ce2e58e5b8872cc 100644 (file)
  */
 package org.mxchange.pizzaapplication.beans.customer;
 
-import java.lang.reflect.Field;
 import java.lang.reflect.InvocationTargetException;
-import java.util.Iterator;
-import java.util.Map;
 import javax.ejb.Stateless;
 import javax.servlet.ServletException;
 import org.mxchange.jcore.client.Client;
@@ -27,7 +24,7 @@ import org.mxchange.jcore.contact.Contact;
 import org.mxchange.jcore.contact.gender.Gender;
 import org.mxchange.jshop.beans.BaseFrameworkBean;
 import org.mxchange.jshop.beans.remote.customer.CustomerSessionBeanRemote;
-import org.mxchange.jshop.customer.ShopCustomer;
+import org.mxchange.jshop.model.customer.ShopCustomer;
 
 /**
  * A customer bean which hides the customer instance
@@ -254,44 +251,11 @@ public class ShopCustomerSessionBean extends BaseFrameworkBean implements Custom
                throw new UnsupportedOperationException("Not supported yet."); //NOI18N
        }
 
-       @Override
-       public Iterator<Map.Entry<Field, Object>> iterator () throws ServletException {
-               try {
-                       // Deligate to "hidden" object
-                       return this.getContact().iterator();
-               } catch (final NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
-                       // Continue to throw
-                       throw new ServletException(ex);
-               }
-       }
-
        @Override
        public void show (final Client client) {
                throw new UnsupportedOperationException("Not supported yet."); //NOI18N
        }
 
-       @Override
-       public Object getValueFromColumn (final String columnName) throws ServletException {
-               try {
-                       // Deligate to "hidden" object
-                       return this.getContact().getValueFromColumn(columnName);
-               } catch (final IllegalArgumentException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
-                       // Continue to throw
-                       throw new ServletException(ex);
-               }
-       }
-
-       @Override
-       public void setValueFromColumn (final String columnName, final Object value) throws ServletException {
-               try {
-                       // Deligate to "hidden" object
-                       this.getContact().setValueFromColumn(columnName, value);
-               } catch (final NoSuchMethodException | IllegalAccessException | IllegalArgumentException | InvocationTargetException ex) {
-                       // Continue to throw
-                       throw new ServletException(ex);
-               }
-       }
-
        /**
         * Setter for Contact instance
         * @param contact Contact instance to set
index d67ea8172edf090a1e601ed3f625c1d88ee26e63..dea48c2333abce036dfe1c3b6371dbbf10df5b30 100644 (file)
@@ -23,13 +23,10 @@ import java.util.Deque;
 import javax.annotation.PostConstruct;
 import javax.ejb.Stateless;
 import javax.servlet.ServletException;
-import org.mxchange.jcore.exceptions.BadTokenException;
-import org.mxchange.jcore.exceptions.CorruptedDatabaseFileException;
-import org.mxchange.jcore.exceptions.UnsupportedDatabaseBackendException;
 import org.mxchange.jshop.beans.BaseFrameworkBean;
 import org.mxchange.jshop.beans.remote.shop.ShopSessionBeanRemote;
-import org.mxchange.jshop.category.Category;
-import org.mxchange.jshop.product.Product;
+import org.mxchange.jshop.model.category.Category;
+import org.mxchange.jshop.model.product.Product;
 import org.mxchange.pizzaapplication.application.PizzaApplication;
 import org.mxchange.pizzaapplication.application.PizzaServiceApplication;
 
@@ -75,7 +72,7 @@ public class PizzaServiceSessionBean extends BaseFrameworkBean implements ShopSe
                try {
                        // Call init method
                        this.app.init();
-               } catch (final UnsupportedDatabaseBackendException | SQLException | IOException | BadTokenException ex) {
+               } catch (final SQLException | IOException ex) {
                        // Continue to throw
                        throw new RuntimeException(ex);
                }
@@ -85,7 +82,7 @@ public class PizzaServiceSessionBean extends BaseFrameworkBean implements ShopSe
        public Deque<Product> getAvailableProducts () throws ServletException {
                try {
                        return this.app.getAvailableProducts();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new ServletException(ex);
                }
@@ -95,7 +92,7 @@ public class PizzaServiceSessionBean extends BaseFrameworkBean implements ShopSe
        public Deque<Product> getAllProducts () throws ServletException {
                try {
                        return this.app.getAllProducts();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new ServletException(ex);
                }
@@ -105,7 +102,7 @@ public class PizzaServiceSessionBean extends BaseFrameworkBean implements ShopSe
        public Deque<Category> getAllCategories () throws ServletException {
                try {
                        return this.app.getAllCategories();
-               } catch (final IOException | BadTokenException | SQLException | CorruptedDatabaseFileException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
+               } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) {
                        // Continue to throw
                        throw new ServletException(ex);
                }
index a7b826ab9888fd09bc9ffbeae87109c8d3a43273..3fecb7f1fb90956661d69240f14aac0e4218fbe1 100644 (file)
@@ -24,8 +24,8 @@ import javax.servlet.jsp.tagext.BodyTagSupport;
 import org.apache.logging.log4j.LogManager;
 import org.apache.logging.log4j.Logger;
 import org.mxchange.jshop.beans.basket.BasketBean;
-import org.mxchange.jshop.item.AddableBasketItem;
-import org.mxchange.jshop.product.Product;
+import org.mxchange.jshop.model.item.AddableBasketItem;
+import org.mxchange.jshop.model.product.Product;
 import org.mxchange.pizzaapplication.beans.controller.PizzaBean;
 
 /**