From: Roland Haeder Date: Sat, 5 Sep 2015 13:05:50 +0000 (+0200) Subject: Renaming season is not yet over ... ;-) X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=ea1172472b6bd929318e20bddecf68771497439b;p=pizzaservice-war.git Renaming season is not yet over ... ;-) Signed-off-by:Roland Häder --- diff --git a/lib/jcore-ejb.jar b/lib/jcore-ejb.jar deleted file mode 100644 index 261eaa84..00000000 Binary files a/lib/jcore-ejb.jar and /dev/null differ diff --git a/lib/jcoreee.jar b/lib/jcoreee.jar new file mode 100644 index 00000000..5f807686 Binary files /dev/null and b/lib/jcoreee.jar differ diff --git a/nbproject/build-impl.xml b/nbproject/build-impl.xml index 08650522..15f68d0d 100644 --- a/nbproject/build-impl.xml +++ b/nbproject/build-impl.xml @@ -1023,7 +1023,7 @@ exists or setup the property manually. For example like this: - + @@ -1038,7 +1038,7 @@ exists or setup the property manually. For example like this: - + diff --git a/nbproject/project.properties b/nbproject/project.properties index 97210ba9..86ee86fb 100644 --- a/nbproject/project.properties +++ b/nbproject/project.properties @@ -33,7 +33,7 @@ file.reference.commons-codec-1.10.jar=lib/commons-codec-1.10.jar file.reference.commons-lang3-3.4.jar=lib/commons-lang3-3.4.jar file.reference.gf-client.jar=lib/gf-client.jar file.reference.jcore.jar=lib/jcore.jar -file.reference.jcore-ejb.jar=lib/jcore-ejb.jar +file.reference.jcoreee.jar=lib/jcoreee.jar file.reference.jshop-core.jar=lib/jshop-core.jar file.reference.jshop-ejb.jar=lib/jshop-ejb.jar file.reference.log4j-api-2.3.jar=lib/log4j-api-2.3.jar @@ -54,7 +54,7 @@ j2ee.server.type=gfv3ee6 jar.compress=false javac.classpath=\ ${file.reference.jcore.jar}:\ - ${file.reference.jcore-ejb.jar}:\ + ${file.reference.jcoreee.jar}:\ ${file.reference.jshop-core.jar}:\ ${file.reference.jshop-ejb.jar}:\ ${reference.PizzaService-lib.jar}:\ @@ -104,7 +104,7 @@ run.test.classpath=\ runmain.jvmargs= source.encoding=UTF-8 source.reference.jcore.jar=../jcore/src/ -source.reference.jcore-ejb.jar=../jcore-ejb/src/ +source.reference.jcoreee.jar=../jcoreee/src/ source.reference.jshop-core.jar=../jshop-core/src/ source.reference.jshop-ejb.jar=../jshop-ejb/src/ source.root=src diff --git a/nbproject/project.xml b/nbproject/project.xml index 7628060f..257793f7 100644 --- a/nbproject/project.xml +++ b/nbproject/project.xml @@ -11,7 +11,7 @@ WEB-INF/lib - ${file.reference.jcore-ejb.jar} + ${file.reference.jcoreee.jar} WEB-INF/lib diff --git a/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaServiceWebBean.java b/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaServiceWebBean.java index dd896a6c..e69bba25 100644 --- a/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaServiceWebBean.java +++ b/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaServiceWebBean.java @@ -20,18 +20,17 @@ import java.io.IOException; import java.lang.reflect.InvocationTargetException; import java.rmi.RemoteException; import java.sql.SQLException; -import java.text.MessageFormat; import java.util.Deque; import java.util.Iterator; import javax.annotation.PostConstruct; import javax.enterprise.context.SessionScoped; import javax.faces.FacesException; import javax.inject.Named; +import org.mxchange.jcoreee.beans.BaseFrameworkBean; import org.mxchange.jshopcore.exceptions.CategoryTitleAlreadyUsedException; import org.mxchange.jshopcore.exceptions.ProductTitleAlreadyUsedException; import org.mxchange.jshopcore.model.category.Category; import org.mxchange.jshopcore.model.product.Product; -import org.mxchange.jshopejb.beans.BaseFrameworkBean; /** * Main application class @@ -65,13 +64,10 @@ public class PizzaServiceWebBean extends BaseFrameworkBean implements PizzaWebBe @PostConstruct public void init () throws FacesException { // Trace message - this.getLogger().trace(MessageFormat.format("application={0} - CALLED!", this.getApplication())); //NOI18N + this.getLogger().trace("CALLED!"); //NOI18N - // Must not be null - if (this.getApplication() == null) { - // Abort here - throw new NullPointerException("application is null"); //NOI18N - } + // Super call + super.init(); try { // Call init method @@ -82,12 +78,6 @@ public class PizzaServiceWebBean extends BaseFrameworkBean implements PizzaWebBe } } - @Override - @Deprecated - public String getPrintableProductAvailability (final Product product) { - return this.app.getPrintableProductAvailability(product); - } - @Override public Iterator getAvailableProductsIterator () throws RemoteException { try { @@ -167,36 +157,4 @@ public class PizzaServiceWebBean extends BaseFrameworkBean implements PizzaWebBe throw new RemoteException("doAdminAddProduct() failed.", ex); } } - - @Override - @Deprecated - public String getPrintableProduktCategory (final Product product) throws RemoteException { - try { - return this.app.getPrintableProductCategory(product); - } catch (final IOException | SQLException | NoSuchMethodException | IllegalAccessException | InvocationTargetException ex) { - // Continue to throw - throw new RemoteException("getPrintableProduktCategory() failed.", ex); - } - } - - @Override - @Deprecated - public void doAdminHandleProductForms () throws RemoteException { - // Deprecated method called - throw new UnsupportedOperationException("Deprecated method called"); - } - - @Override - @Deprecated - public void doAdminHandleCategoryForms () throws RemoteException { - // Deprecated method called - throw new UnsupportedOperationException("Deprecated method called"); - } - - @Override - @Deprecated - public String generateLinkForParent (final Category category) { - // Deligate to app - return this.app.generateLinkForParent(category); - } } diff --git a/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaWebBean.java b/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaWebBean.java index f24dad1e..451f9f70 100644 --- a/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaWebBean.java +++ b/src/java/org/mxchange/pizzaapplication/beans/controller/PizzaWebBean.java @@ -19,24 +19,17 @@ package org.mxchange.pizzaapplication.beans.controller; import java.rmi.RemoteException; import java.util.Deque; import java.util.Iterator; -import javax.faces.FacesException; +import org.mxchange.jcoreee.beans.FrameworkBean; import org.mxchange.jshopcore.exceptions.CategoryTitleAlreadyUsedException; import org.mxchange.jshopcore.exceptions.ProductTitleAlreadyUsedException; import org.mxchange.jshopcore.model.category.Category; import org.mxchange.jshopcore.model.product.Product; -import org.mxchange.jshopejb.beans.FrameworkBean; /** * * @author Roland Haeder */ public interface PizzaWebBean extends FrameworkBean { - /** - * Initializes this instance - * - * @throws FacesException If something was wrong - */ - public void init () throws FacesException; /** * Some "getter" for an iterator of only available products @@ -86,39 +79,6 @@ public interface PizzaWebBean extends FrameworkBean { */ public Deque getAllCategories () throws RemoteException; - /** - * Generates a link for category's parent category. If none is given, the method will return only a small - * note. - * - * @param category Category instance - * @return HTML link for category's parent category - * @deprecated Old lost code - */ - @Deprecated - public String generateLinkForParent (final Category category); - - /** - * Checks if given Product instance is available and returns a printable - * (human-readable) string. - * - * @param product Product instance to check - * @return Human-readable version of product availability - * @deprecated Old lost code - */ - @Deprecated - public String getPrintableProductAvailability (final Product product); - - /** - * Returns a printable (human-readable) string of product's category - * - * @param product Product instance to check - * @return Human-readable version of product availability - * @throws java.rmi.RemoteException If something unexpected happened - * @deprecated Old lost code - */ - @Deprecated - public String getPrintableProduktCategory (final Product product) throws RemoteException; - /** * Adds given category data from request to database * @@ -136,22 +96,4 @@ public interface PizzaWebBean extends FrameworkBean { * @throws org.mxchange.jshopcore.exceptions.ProductTitleAlreadyUsedException If the given product title is already used */ public void doAdminAddProduct (final Product product) throws RemoteException, ProductTitleAlreadyUsedException; - - /** - * Handles admin product form requests - * - * @throws RemoteException If something unexpected happened - * @deprecated Old lost code - */ - @Deprecated - public void doAdminHandleProductForms () throws RemoteException; - - /** - * Handles admin category form requests - * - * @throws RemoteException If something unexpected happened - * @deprecated Old lost code - */ - @Deprecated - public void doAdminHandleCategoryForms () throws RemoteException; } diff --git a/src/java/org/mxchange/pizzaapplication/beans/customer/CustomerWebBean.java b/src/java/org/mxchange/pizzaapplication/beans/customer/CustomerWebBean.java index 7abb046c..fe9dec1b 100644 --- a/src/java/org/mxchange/pizzaapplication/beans/customer/CustomerWebBean.java +++ b/src/java/org/mxchange/pizzaapplication/beans/customer/CustomerWebBean.java @@ -16,8 +16,7 @@ */ package org.mxchange.pizzaapplication.beans.customer; -import org.mxchange.jcore.model.contact.gender.Gender; -import org.mxchange.jshopejb.beans.FrameworkBean; +import org.mxchange.jcoreee.beans.FrameworkBean; /** * An interface for customer beans @@ -25,227 +24,4 @@ import org.mxchange.jshopejb.beans.FrameworkBean; * @author Roland Haeder */ public interface CustomerWebBean extends FrameworkBean { - /** - * Some "getter" for translated gender of the contact - * - * @return Translated / human-readable gender - */ - public String getTranslatedGender (); - - /** - * Gender of the contact - * - * @return the gender - */ - public Gender getGender (); - - /** - * Gender of the contact - * - * @param gender the gender to set - */ - public void setGender (final Gender gender); - - /** - * First name - * - * @return the first name - */ - public String getFirstName (); - - /** - * First name - * - * @param firstName the first name to set - */ - public void setFirstName (final String firstName); - - /** - * Family name - * - * @return the familyName - */ - public String getFamilyName (); - - /** - * Family name - * - * @param familyName the familyName to set - */ - public void setFamilyName (final String familyName); - - /** - * Companyname - * - * @return the companyName - */ - public String getCompanyName (); - - /** - * Companyname - * - * @param companyName the companyName to set - */ - public void setCompanyName (final String companyName); - - /** - * Street - * - * @return the street - */ - public String getStreet (); - - /** - * Street - * - * @param street the street to set - */ - public void setStreet (final String street); - - /** - * House number - * - * @return the houseNumber - */ - public Long getHouseNumber (); - - /** - * House number - * - * @param houseNumber the houseNumber to set - */ - public void setHouseNumber (final Long houseNumber); - - /** - * ZIP code - * - * @return the zipCode - */ - public Long getZipCode (); - - /** - * ZIP code - * - * @param zipCode the zipCode to set - */ - public void setZipCode (final Long zipCode); - - /** - * City - * - * @return the city - */ - public String getCity (); - - /** - * City - * - * @param city the city to set - */ - public void setCity (final String city); - - /** - * Country code - * - * @return the countryCode - */ - public String getCountryCode (); - - /** - * Country code - * - * @param countryCode the countryCode to set - */ - public void setCountryCode (final String countryCode); - - /** - * Email address - * - * @return the emailAddress - */ - public String getEmailAddress (); - - /** - * Email address - * - * @param emailAddress the emailAddress to set - */ - public void setEmailAddress (final String emailAddress); - - /** - * Phone number - * - * @return the phoneNumber - */ - public String getPhoneNumber (); - - /** - * Phone number - * - * @param phoneNumber the phoneNumber to set - */ - public void setPhoneNumber (final String phoneNumber); - - /** - * Fax number - * - * @return the faxNumber - */ - public String getFaxNumber (); - - /** - * Fax number - * - * @param faxNumber the faxNumber to set - */ - public void setFaxNumber (final String faxNumber); - - /** - * Cellphone number - * - * @return the cellphoneNumber - */ - public String getCellphoneNumber (); - - /** - * Cellphone number - * - * @param cellphoneNumber the cellphoneNumber to set - */ - public void setCellphoneNumber (final String cellphoneNumber); - - /** - * Birth day - * - * @return the birthday - */ - public String getBirthday (); - - /** - * Birth day - * - * @param birthday the birthday to set - */ - public void setBirthday (final String birthday); - - /** - * Comments - * - * @return the comment - */ - public String getComment (); - - /** - * Comments - * - * @param comment the comment to set - */ - public void setComment (final String comment); - - /** - * Checks whether the contact is user's own data - * - * @return Own data? - */ - public boolean isOwnContact (); } diff --git a/src/java/org/mxchange/pizzaapplication/beans/customer/PizzaServiceCustomerWebBean.java b/src/java/org/mxchange/pizzaapplication/beans/customer/PizzaServiceCustomerWebBean.java index 0c5806ad..159413a2 100644 --- a/src/java/org/mxchange/pizzaapplication/beans/customer/PizzaServiceCustomerWebBean.java +++ b/src/java/org/mxchange/pizzaapplication/beans/customer/PizzaServiceCustomerWebBean.java @@ -18,10 +18,7 @@ package org.mxchange.pizzaapplication.beans.customer; import javax.enterprise.context.SessionScoped; import javax.inject.Named; -import org.mxchange.jcore.model.contact.gender.Gender; -import org.mxchange.jshopcore.model.customer.Customer; -import org.mxchange.jshopcore.model.customer.ShopCustomer; -import org.mxchange.jshopejb.beans.BaseFrameworkBean; +import org.mxchange.jcoreee.beans.BaseFrameworkBean; /** * A customer bean which hides the customer instance @@ -36,222 +33,9 @@ public class PizzaServiceCustomerWebBean extends BaseFrameworkBean implements Cu */ private static final long serialVersionUID = 542145347916L; - /** - * Customer instance - */ - private final Customer customer; - /** * Default constructor */ public PizzaServiceCustomerWebBean () { - // Instance customer - this.customer = new ShopCustomer(); - } - - @Override - public String getBirthday () { - // Deligate to "hidden" object - return this.getCustomer().getBirthday(); - } - - @Override - public void setBirthday (final String birthday) { - // Deligate to "hidden" object - this.getCustomer().setBirthday(birthday); - } - - @Override - public String getCellphoneNumber () { - // Deligate to "hidden" object - return this.getCustomer().getCellphoneNumber(); - } - - @Override - public void setCellphoneNumber (final String cellphoneNumber) { - // Deligate to "hidden" object - this.getCustomer().setCellphoneNumber(cellphoneNumber); - } - - @Override - public String getCity () { - // Deligate to "hidden" object - return this.getCustomer().getCity(); - } - - @Override - public void setCity (final String city) { - // Deligate to "hidden" object - this.getCustomer().setCity(city); - } - - @Override - public String getComment () { - // Deligate to "hidden" object - return this.getCustomer().getComment(); - } - - @Override - public void setComment (final String comment) { - // Deligate to "hidden" object - this.getCustomer().setComment(comment); - } - - @Override - public String getCompanyName () { - // Deligate to "hidden" object - return this.getCustomer().getCompanyName(); - } - - @Override - public void setCompanyName (final String companyName) { - // Deligate to "hidden" object - this.getCustomer().setCompanyName(companyName); - } - - @Override - public String getCountryCode () { - // Deligate to "hidden" object - return this.getCustomer().getCountryCode(); - } - - @Override - public void setCountryCode (final String countryCode) { - // Deligate to "hidden" object - this.getCustomer().setCountryCode(countryCode); - } - - @Override - public String getEmailAddress () { - // Deligate to "hidden" object - return this.getCustomer().getEmailAddress(); - } - - @Override - public void setEmailAddress (final String emailAddress) { - // Deligate to "hidden" object - this.getCustomer().setEmailAddress(emailAddress); - } - - @Override - public String getFamilyName () { - // Trace call - //* NOISY-DEBUG: */ this.getLogger().trace("CALLED!"); - - // Deligate to "hidden" object - return this.getCustomer().getFamilyName(); - } - - @Override - public void setFamilyName (final String familyName) { - // Trace call - //* NOISY-DEBUG: */ this.getLogger().trace(MessageFormat.format("familyName={0} - CALLED!", familyName)); - - // Deligate to "hidden" object - this.getCustomer().setFamilyName(familyName); - } - - @Override - public String getFaxNumber () { - // Deligate to "hidden" object - return this.getCustomer().getFaxNumber(); - } - - @Override - public void setFaxNumber (final String faxNumber) { - // Deligate to "hidden" object - this.getCustomer().setFaxNumber(faxNumber); - } - - @Override - public Gender getGender () { - // Deligate to "hidden" object - return this.getCustomer().getGender(); - } - - @Override - public void setGender (final Gender gender) { - // Deligate to "hidden" object - this.getCustomer().setGender(gender); - } - - @Override - public Long getHouseNumber () { - // Deligate to "hidden" object - return this.getCustomer().getHouseNumber(); - } - - @Override - public void setHouseNumber (final Long houseNumber) { - // Deligate to "hidden" object - this.getCustomer().setHouseNumber(houseNumber); - } - - @Override - public String getPhoneNumber () { - // Deligate to "hidden" object - return this.getCustomer().getPhoneNumber(); - } - - @Override - public void setPhoneNumber (final String phoneNumber) { - // Deligate to "hidden" object - this.getCustomer().setPhoneNumber(phoneNumber); - } - - @Override - public String getStreet () { - // Deligate to "hidden" object - return this.getCustomer().getStreet(); - } - - @Override - public void setStreet (final String street) { - // Deligate to "hidden" object - this.getCustomer().setStreet(street); - } - - @Override - public String getFirstName () { - // Deligate to "hidden" object - return this.getCustomer().getFirstName(); - } - - @Override - public void setFirstName (final String firstName) { - // Deligate to "hidden" object - this.getCustomer().setFirstName(firstName); - } - - @Override - public String getTranslatedGender () { - // Deligate to "hidden" object - return this.getCustomer().getTranslatedGender(); - } - - @Override - public Long getZipCode () { - // Deligate to "hidden" object - return this.getCustomer().getZipCode(); - } - - @Override - public void setZipCode (final Long zipCode) { - // Deligate to "hidden" object - this.getCustomer().setZipCode(zipCode); - } - - @Override - public boolean isOwnContact () { - throw new UnsupportedOperationException("Not supported yet."); //NOI18N - } - - /** - * Getter for Customer instance - * - * @return Contact instance - */ - private Customer getCustomer () { - return this.customer; } } diff --git a/src/java/org/mxchange/pizzaapplication/beans/enums/DataWebBean.java b/src/java/org/mxchange/pizzaapplication/beans/enums/DataWebBean.java index 327ac2b3..5fe8435d 100644 --- a/src/java/org/mxchange/pizzaapplication/beans/enums/DataWebBean.java +++ b/src/java/org/mxchange/pizzaapplication/beans/enums/DataWebBean.java @@ -18,7 +18,7 @@ package org.mxchange.pizzaapplication.beans.enums; import java.util.List; import org.mxchange.jcore.model.contact.gender.Gender; -import org.mxchange.jshopejb.beans.FrameworkBean; +import org.mxchange.jcoreee.beans.FrameworkBean; /** * An interface for data beans diff --git a/src/java/org/mxchange/pizzaapplication/beans/enums/PizzaServiceDataWebBean.java b/src/java/org/mxchange/pizzaapplication/beans/enums/PizzaServiceDataWebBean.java index e9655c12..87ed577b 100644 --- a/src/java/org/mxchange/pizzaapplication/beans/enums/PizzaServiceDataWebBean.java +++ b/src/java/org/mxchange/pizzaapplication/beans/enums/PizzaServiceDataWebBean.java @@ -22,7 +22,7 @@ import java.util.List; import javax.enterprise.context.ApplicationScoped; import javax.inject.Named; import org.mxchange.jcore.model.contact.gender.Gender; -import org.mxchange.jshopejb.beans.BaseFrameworkBean; +import org.mxchange.jcoreee.beans.BaseFrameworkBean; /** * A customer bean which hides the customer instance