</condition>
</fail>
<target depends="dist,javadoc" description="Build whole project." name="default"/>
- <!--
- INITIALIZATION SECTION
+ <!--
+ INITIALIZATION SECTION
-->
<target name="-pre-init">
<!-- Empty placeholder for easier customization. -->
<target name="-init-taskdefs">
<fail unless="libs.CopyLibs.classpath">
The libs.CopyLibs.classpath property is not set up.
-This property must point to
+This property must point to
org-netbeans-modules-java-j2seproject-copylibstask.jar file which is part
-of NetBeans IDE installation and is usually located at
+of NetBeans IDE installation and is usually located at
<netbeans_installation>/java<version>/ant/extra folder.
Either open the project in the IDE and make sure CopyLibs library
exists or setup the property manually. For example like this:
<target if="is.jars.in.ejbjar" name="-library-inclusion-in-archive-by-user">
<copyfiles files="${file.reference.jcore.jar}" todir="${build.classes.dir}"/>
<copyfiles files="${file.reference.jcoreee.jar}" todir="${build.classes.dir}"/>
- <copyfiles files="${file.reference.jcountry-core.jar}" todir="${build.classes.dir}"/>
- <copyfiles files="${file.reference.jcountry-lib.jar}" todir="${build.classes.dir}"/>
<copyfiles files="${file.reference.jcore-logger-lib.jar}" todir="${build.classes.dir}"/>
<copyfiles files="${file.reference.jcontacts-core.jar}" todir="${build.classes.dir}"/>
<copyfiles files="${file.reference.jcontacts-lib.jar}" todir="${build.classes.dir}"/>
- <copyfiles files="${file.reference.juser-core.jar}" todir="${build.classes.dir}"/>
- <copyfiles files="${file.reference.juser-lib.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.jcontacts-business-core.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.jcountry-core.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.jcountry-lib.jar}" todir="${build.classes.dir}"/>
<copyfiles files="${file.reference.jphone-core.jar}" todir="${build.classes.dir}"/>
<copyfiles files="${file.reference.jphone-lib.jar}" todir="${build.classes.dir}"/>
- <copyfiles files="${file.reference.jshop-core.jar}" todir="${build.classes.dir}"/>
- <copyfiles files="${file.reference.jshop-ee-lib.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.juser-core.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.juser-lib.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.jmailer-ee.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.jcustomer-core.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.jcustomer-lib.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.pizzaservice-core.jar}" todir="${build.classes.dir}"/>
+ <copyfiles files="${file.reference.pizzaservice-mailer.jar}" todir="${build.classes.dir}"/>
<copyfiles files="${reference.PizzaService-lib.jar}" todir="${build.classes.dir}"/>
- <copyfiles files="${file.reference.cdi-api.jar}" todir="${build.classes.dir}"/>
</target>
<target if="is.server.weblogic" name="-library-inclusion-in-archive-weblogic">
<basename file="${file.reference.jcore.jar}" property="manifest.file.reference.jcore.jar"/>
<basename file="${file.reference.jcoreee.jar}" property="manifest.file.reference.jcoreee.jar"/>
- <basename file="${file.reference.jcountry-core.jar}" property="manifest.file.reference.jcountry-core.jar"/>
- <basename file="${file.reference.jcountry-lib.jar}" property="manifest.file.reference.jcountry-lib.jar"/>
<basename file="${file.reference.jcore-logger-lib.jar}" property="manifest.file.reference.jcore-logger-lib.jar"/>
<basename file="${file.reference.jcontacts-core.jar}" property="manifest.file.reference.jcontacts-core.jar"/>
<basename file="${file.reference.jcontacts-lib.jar}" property="manifest.file.reference.jcontacts-lib.jar"/>
- <basename file="${file.reference.juser-core.jar}" property="manifest.file.reference.juser-core.jar"/>
- <basename file="${file.reference.juser-lib.jar}" property="manifest.file.reference.juser-lib.jar"/>
+ <basename file="${file.reference.jcontacts-business-core.jar}" property="manifest.file.reference.jcontacts-business-core.jar"/>
+ <basename file="${file.reference.jcountry-core.jar}" property="manifest.file.reference.jcountry-core.jar"/>
+ <basename file="${file.reference.jcountry-lib.jar}" property="manifest.file.reference.jcountry-lib.jar"/>
<basename file="${file.reference.jphone-core.jar}" property="manifest.file.reference.jphone-core.jar"/>
<basename file="${file.reference.jphone-lib.jar}" property="manifest.file.reference.jphone-lib.jar"/>
- <basename file="${file.reference.jshop-core.jar}" property="manifest.file.reference.jshop-core.jar"/>
- <basename file="${file.reference.jshop-ee-lib.jar}" property="manifest.file.reference.jshop-ee-lib.jar"/>
+ <basename file="${file.reference.juser-core.jar}" property="manifest.file.reference.juser-core.jar"/>
+ <basename file="${file.reference.juser-lib.jar}" property="manifest.file.reference.juser-lib.jar"/>
+ <basename file="${file.reference.jmailer-ee.jar}" property="manifest.file.reference.jmailer-ee.jar"/>
+ <basename file="${file.reference.jcustomer-core.jar}" property="manifest.file.reference.jcustomer-core.jar"/>
+ <basename file="${file.reference.jcustomer-lib.jar}" property="manifest.file.reference.jcustomer-lib.jar"/>
+ <basename file="${file.reference.pizzaservice-core.jar}" property="manifest.file.reference.pizzaservice-core.jar"/>
+ <basename file="${file.reference.pizzaservice-mailer.jar}" property="manifest.file.reference.pizzaservice-mailer.jar"/>
<basename file="${reference.PizzaService-lib.jar}" property="manifest.reference.PizzaService-lib.jar"/>
- <basename file="${file.reference.cdi-api.jar}" property="manifest.file.reference.cdi-api.jar"/>
<manifest file="${build.ear.classes.dir}/META-INF/MANIFEST.MF" mode="update">
- <attribute name="Extension-List" value="jar-1 jar-2 jar-3 jar-4 jar-5 jar-6 jar-7 jar-8 jar-9 jar-10 jar-11 jar-12 jar-13 jar-14 jar-15 "/>
+ <attribute name="Extension-List" value="jar-1 jar-2 jar-3 jar-4 jar-5 jar-6 jar-7 jar-8 jar-9 jar-10 jar-11 jar-12 jar-13 jar-14 jar-15 jar-16 jar-17 jar-18 "/>
<attribute name="jar-1-Extension-Name" value="${manifest.file.reference.jcore.jar}"/>
<attribute name="jar-2-Extension-Name" value="${manifest.file.reference.jcoreee.jar}"/>
- <attribute name="jar-3-Extension-Name" value="${manifest.file.reference.jcountry-core.jar}"/>
- <attribute name="jar-4-Extension-Name" value="${manifest.file.reference.jcountry-lib.jar}"/>
- <attribute name="jar-5-Extension-Name" value="${manifest.file.reference.jcore-logger-lib.jar}"/>
- <attribute name="jar-6-Extension-Name" value="${manifest.file.reference.jcontacts-core.jar}"/>
- <attribute name="jar-7-Extension-Name" value="${manifest.file.reference.jcontacts-lib.jar}"/>
- <attribute name="jar-8-Extension-Name" value="${manifest.file.reference.juser-core.jar}"/>
- <attribute name="jar-9-Extension-Name" value="${manifest.file.reference.juser-lib.jar}"/>
- <attribute name="jar-10-Extension-Name" value="${manifest.file.reference.jphone-core.jar}"/>
- <attribute name="jar-11-Extension-Name" value="${manifest.file.reference.jphone-lib.jar}"/>
- <attribute name="jar-12-Extension-Name" value="${manifest.file.reference.jshop-core.jar}"/>
- <attribute name="jar-13-Extension-Name" value="${manifest.file.reference.jshop-ee-lib.jar}"/>
- <attribute name="jar-14-Extension-Name" value="${manifest.reference.PizzaService-lib.jar}"/>
- <attribute name="jar-15-Extension-Name" value="${manifest.file.reference.cdi-api.jar}"/>
+ <attribute name="jar-3-Extension-Name" value="${manifest.file.reference.jcore-logger-lib.jar}"/>
+ <attribute name="jar-4-Extension-Name" value="${manifest.file.reference.jcontacts-core.jar}"/>
+ <attribute name="jar-5-Extension-Name" value="${manifest.file.reference.jcontacts-lib.jar}"/>
+ <attribute name="jar-6-Extension-Name" value="${manifest.file.reference.jcontacts-business-core.jar}"/>
+ <attribute name="jar-7-Extension-Name" value="${manifest.file.reference.jcountry-core.jar}"/>
+ <attribute name="jar-8-Extension-Name" value="${manifest.file.reference.jcountry-lib.jar}"/>
+ <attribute name="jar-9-Extension-Name" value="${manifest.file.reference.jphone-core.jar}"/>
+ <attribute name="jar-10-Extension-Name" value="${manifest.file.reference.jphone-lib.jar}"/>
+ <attribute name="jar-11-Extension-Name" value="${manifest.file.reference.juser-core.jar}"/>
+ <attribute name="jar-12-Extension-Name" value="${manifest.file.reference.juser-lib.jar}"/>
+ <attribute name="jar-13-Extension-Name" value="${manifest.file.reference.jmailer-ee.jar}"/>
+ <attribute name="jar-14-Extension-Name" value="${manifest.file.reference.jcustomer-core.jar}"/>
+ <attribute name="jar-15-Extension-Name" value="${manifest.file.reference.jcustomer-lib.jar}"/>
+ <attribute name="jar-16-Extension-Name" value="${manifest.file.reference.pizzaservice-core.jar}"/>
+ <attribute name="jar-17-Extension-Name" value="${manifest.file.reference.pizzaservice-mailer.jar}"/>
+ <attribute name="jar-18-Extension-Name" value="${manifest.reference.PizzaService-lib.jar}"/>
</manifest>
</target>
<target depends="compile" name="library-inclusion-in-manifest">
<copyfiles files="${file.reference.jcore.jar}" todir="${dist.ear.dir}/lib"/>
<copyfiles files="${file.reference.jcoreee.jar}" todir="${dist.ear.dir}/lib"/>
- <copyfiles files="${file.reference.jcountry-core.jar}" todir="${dist.ear.dir}/lib"/>
- <copyfiles files="${file.reference.jcountry-lib.jar}" todir="${dist.ear.dir}/lib"/>
<copyfiles files="${file.reference.jcore-logger-lib.jar}" todir="${dist.ear.dir}/lib"/>
<copyfiles files="${file.reference.jcontacts-core.jar}" todir="${dist.ear.dir}/lib"/>
<copyfiles files="${file.reference.jcontacts-lib.jar}" todir="${dist.ear.dir}/lib"/>
- <copyfiles files="${file.reference.juser-core.jar}" todir="${dist.ear.dir}/lib"/>
- <copyfiles files="${file.reference.juser-lib.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.jcontacts-business-core.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.jcountry-core.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.jcountry-lib.jar}" todir="${dist.ear.dir}/lib"/>
<copyfiles files="${file.reference.jphone-core.jar}" todir="${dist.ear.dir}/lib"/>
<copyfiles files="${file.reference.jphone-lib.jar}" todir="${dist.ear.dir}/lib"/>
- <copyfiles files="${file.reference.jshop-core.jar}" todir="${dist.ear.dir}/lib"/>
- <copyfiles files="${file.reference.jshop-ee-lib.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.juser-core.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.juser-lib.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.jmailer-ee.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.jcustomer-core.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.jcustomer-lib.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.pizzaservice-core.jar}" todir="${dist.ear.dir}/lib"/>
+ <copyfiles files="${file.reference.pizzaservice-mailer.jar}" todir="${dist.ear.dir}/lib"/>
<copyfiles files="${reference.PizzaService-lib.jar}" todir="${dist.ear.dir}/lib"/>
- <copyfiles files="${file.reference.cdi-api.jar}" todir="${dist.ear.dir}/lib"/>
<manifest file="${build.ear.classes.dir}/META-INF/MANIFEST.MF" mode="update"/>
</target>
<target name="-copy-meta-inf">
<minimum-ant-version>1.6.5</minimum-ant-version>
<included-library dirs="200">file.reference.jcore.jar</included-library>
<included-library dirs="200">file.reference.jcoreee.jar</included-library>
- <included-library dirs="200">file.reference.jcountry-core.jar</included-library>
- <included-library dirs="200">file.reference.jcountry-lib.jar</included-library>
<included-library dirs="200">file.reference.jcore-logger-lib.jar</included-library>
<included-library dirs="200">file.reference.jcontacts-core.jar</included-library>
<included-library dirs="200">file.reference.jcontacts-lib.jar</included-library>
- <included-library dirs="200">file.reference.juser-core.jar</included-library>
- <included-library dirs="200">file.reference.juser-lib.jar</included-library>
+ <included-library dirs="200">file.reference.jcontacts-business-core.jar</included-library>
+ <included-library dirs="200">file.reference.jcountry-core.jar</included-library>
+ <included-library dirs="200">file.reference.jcountry-lib.jar</included-library>
<included-library dirs="200">file.reference.jphone-core.jar</included-library>
<included-library dirs="200">file.reference.jphone-lib.jar</included-library>
- <included-library dirs="200">file.reference.jshop-core.jar</included-library>
- <included-library dirs="200">file.reference.jshop-ee-lib.jar</included-library>
+ <included-library dirs="200">file.reference.juser-core.jar</included-library>
+ <included-library dirs="200">file.reference.juser-lib.jar</included-library>
+ <included-library dirs="200">file.reference.jmailer-ee.jar</included-library>
+ <included-library dirs="200">file.reference.jcustomer-core.jar</included-library>
+ <included-library dirs="200">file.reference.jcustomer-lib.jar</included-library>
+ <included-library dirs="200">file.reference.pizzaservice-core.jar</included-library>
+ <included-library dirs="200">file.reference.pizzaservice-mailer.jar</included-library>
<included-library dirs="200">reference.PizzaService-lib.jar</included-library>
- <included-library dirs="200">file.reference.cdi-api.jar</included-library>
<source-roots>
<root id="src.dir"/>
</source-roots>
--- /dev/null
+/*
+ * Copyright (C) 2016 Roland Haeder
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+package org.mxchange.pizzaapplication.model.customer;
+
+import java.text.MessageFormat;
+import java.util.List;
+import javax.ejb.Stateless;
+import javax.persistence.Query;
+import org.mxchange.jcustomercore.model.customer.Customer;
+import org.mxchange.pizzaaplication.database.BasePizzaDatabaseBean;
+
+/**
+ * A stateless administrative customer session bean (EJB)
+ * <p>
+ * @author Roland Haeder<roland@mxchange.org>
+ */
+@Stateless (name = "admincustomer", description = "Administrative bean handling customer data")
+public class PizzaAdminCustomerSessionBean extends BasePizzaDatabaseBean implements PizzaAdminCustomerSessionBeanRemote {
+
+ /**
+ * Serial number
+ */
+ private static final long serialVersionUID = 19_845_893_648_175_427L;
+
+ @Override
+ @SuppressWarnings ("unchecked")
+ public List<Customer> allCustomers () {
+ // Trace message
+ this.getLoggerBeanLocal().logTrace("allCustomers: CALLED!"); //NOI18N
+
+ // Get named query
+ Query query = this.getEntityManager().createNamedQuery("AllCustomers", List.class); //NOI18N
+
+ // Get result
+ List<Customer> customers = query.getResultList();
+
+ // Trace message
+ this.getLoggerBeanLocal().logTrace(MessageFormat.format("allCustomers: customers.size()={0} - EXIT!", customers.size())); //NOI18N
+
+ // Return full list
+ return customers;
+ }
+
+}
--- /dev/null
+/*
+ * Copyright (C) 2016 Roland Haeder
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+package org.mxchange.pizzaapplication.model.customer;
+
+import de.chotime.jratecalc.model.customer.RateCalcCustomerSessionBeanRemote;
+import javax.ejb.Stateless;
+import org.mxchange.pizzaaplication.database.BasePizzaDatabaseBean;
+;
+import org.mxchange.jcustomercore.exceptions.CustomerAlreadyRegisteredException;
+import org.mxchange.jcustomercore.model.customer.Customer;import org.mxchange.jcustomercore.exceptions.CustomerAlreadyRegisteredException;
+import org.mxchange.jcustomercore.model.customer.Customer;
+
+/**
+ * A stateless customer session bean (EJB)
+ * <p>
+ * @author Roland Haeder<rhaeder@cho-time.de>
+ */
+@Stateless (name = "customer", description = "A bean handling customer data")
+public class PizzaCustomerSessionBean extends BasePizzaDatabaseBean implements RateCalcCustomerSessionBeanRemote {
+
+ /**
+ * Serial number
+ */
+ private static final long serialVersionUID = 15_624_759_104_372L;
+
+ @Override
+ public Customer fillCustomerData (final Customer customer) {
+ throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
+ }
+
+ @Override
+ public boolean isReqistered (final Customer customer) {
+ throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
+ }
+
+ @Override
+ public Customer registerCustomer (final Customer customer) throws CustomerAlreadyRegisteredException {
+ throw new UnsupportedOperationException("Registration by guests is not supported with RateCalc application."); //NOI18N
+ }
+
+}