From: Roland Haeder Date: Sat, 14 May 2016 13:12:19 +0000 (+0200) Subject: fixed name, opps. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=8c2769c5544f1bfefb7512f2d75d5a29e56a98b1;p=pizzaservice-war.git fixed name, opps. Signed-off-by: Roland Häder --- diff --git a/src/java/org/mxchange/pizzaapplication/beans/resendlink/PIzzaResendLinkWebSessionBean.java b/src/java/org/mxchange/pizzaapplication/beans/resendlink/PIzzaResendLinkWebSessionBean.java deleted file mode 100644 index 382a6afa..00000000 --- a/src/java/org/mxchange/pizzaapplication/beans/resendlink/PIzzaResendLinkWebSessionBean.java +++ /dev/null @@ -1,91 +0,0 @@ -/* - * 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 . - */ -package org.mxchange.pizzaapplication.beans.resendlink; - -import javax.enterprise.context.SessionScoped; -import javax.faces.view.facelets.FaceletException; -import javax.inject.Named; -import javax.naming.Context; -import javax.naming.InitialContext; -import javax.naming.NamingException; -import org.mxchange.pizzaapplication.beans.BasePizzaController; - -/** - * A web session bean for resending confirmation link - *

- * @author Roland Haeder - */ -@Named ("resendController") -@SessionScoped -public class PIzzaResendLinkWebSessionBean extends BasePizzaController implements PizzaResendLinkWebSessionController { - - /** - * Serial number - */ - private static final long serialVersionUID = 186_078_724_659_153L; - - /** - * Email address 1 (changing) - */ - private String emailAddress; - - /** - * EJB for resending confirmation link - */ - private ResendLinkSessionBeanRemote emailBean; - - /** - * Default constructor - */ - public PIzzaResendLinkWebSessionBean () { - // Try it - try { - // Get initial context - Context context = new InitialContext(); - - // Try to lookup - this.emailBean = (ResendLinkSessionBeanRemote) context.lookup("java:global/PizzaService-ejb/resendLink!org.mxchange.pizzaapplication.beans.resendlink.ResendLinkSessionBeanRemote"); //NOI18N - } catch (final NamingException e) { - // Throw again - throw new FaceletException(e); - } - } - - @Override - public String doResendLink () { - throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates. - } - - @Override - public String getEmailAddress () { - return this.emailAddress; - } - - @Override - public void setEmailAddress (final String emailAddress) { - this.emailAddress = emailAddress; - } - - /** - * Clears email address fields so the user has to re-enter them - */ - private void clear () { - // Clear fields - this.setEmailAddress(null); - } - -} diff --git a/src/java/org/mxchange/pizzaapplication/beans/resendlink/PizzaResendLinkWebSessionBean.java b/src/java/org/mxchange/pizzaapplication/beans/resendlink/PizzaResendLinkWebSessionBean.java new file mode 100644 index 00000000..fe1c17a1 --- /dev/null +++ b/src/java/org/mxchange/pizzaapplication/beans/resendlink/PizzaResendLinkWebSessionBean.java @@ -0,0 +1,91 @@ +/* + * 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 . + */ +package org.mxchange.pizzaapplication.beans.resendlink; + +import javax.enterprise.context.SessionScoped; +import javax.faces.view.facelets.FaceletException; +import javax.inject.Named; +import javax.naming.Context; +import javax.naming.InitialContext; +import javax.naming.NamingException; +import org.mxchange.pizzaapplication.beans.BasePizzaController; + +/** + * A web session bean for resending confirmation link + *

+ * @author Roland Haeder + */ +@Named ("resendController") +@SessionScoped +public class PizzaResendLinkWebSessionBean extends BasePizzaController implements PizzaResendLinkWebSessionController { + + /** + * Serial number + */ + private static final long serialVersionUID = 186_078_724_659_153L; + + /** + * Email address 1 (changing) + */ + private String emailAddress; + + /** + * EJB for resending confirmation link + */ + private ResendLinkSessionBeanRemote emailBean; + + /** + * Default constructor + */ + public PizzaResendLinkWebSessionBean () { + // Try it + try { + // Get initial context + Context context = new InitialContext(); + + // Try to lookup + this.emailBean = (ResendLinkSessionBeanRemote) context.lookup("java:global/PizzaService-ejb/resendLink!org.mxchange.pizzaapplication.beans.resendlink.ResendLinkSessionBeanRemote"); //NOI18N + } catch (final NamingException e) { + // Throw again + throw new FaceletException(e); + } + } + + @Override + public String doResendLink () { + throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates. + } + + @Override + public String getEmailAddress () { + return this.emailAddress; + } + + @Override + public void setEmailAddress (final String emailAddress) { + this.emailAddress = emailAddress; + } + + /** + * Clears email address fields so the user has to re-enter them + */ + private void clear () { + // Clear fields + this.setEmailAddress(null); + } + +}