From 1e6ec3c65513cfc5a753363c5464c797d9b3b9ae Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Sat, 22 Apr 2017 22:04:26 +0200 Subject: [PATCH] Please cherry-pick: - Let's always call super constructor (not the default one, of course), maybe one day there will be something added - sorted members a bit - some constructors still contain EJB-lookup code, moved to init() (@PostConstruct) method MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../jjobs/beans/BaseJobsController.java | 6 ++++ .../JobsAddressbookWebSessionBean.java | 32 +++++++++-------- .../JobsConfirmationLinkWebRequestBean.java | 2 ++ .../JobsAdminContactWebRequestBean.java | 2 ++ .../contact/JobsContactWebSessionBean.java | 5 ++- .../JobsAdminContactPhoneWebRequestBean.java | 34 ++++++++++++------- .../phone/JobsContactPhoneWebSessionBean.java | 3 ++ .../JobsAdminCountryWebRequestBean.java | 2 ++ .../JobsCountryWebApplicationBean.java | 2 ++ .../JobsEmailChangeWebSessionBean.java | 4 ++- .../JobsFeatureWebApplicationBean.java | 2 ++ .../gender/JobsGenderWebApplicationBean.java | 2 ++ .../helper/JobsWebRequestHelperBean.java | 3 ++ .../JobsLocalizationSessionBean.java | 2 ++ .../JobsUserLoginWebSessionBean.java | 5 ++- .../JobsUserLoginWebSessionController.java | 2 +- ...JobsAdminMobileProviderWebRequestBean.java | 2 ++ .../JobsMobileProviderWebRequestBean.java | 2 ++ .../phone/JobsAdminPhoneWebRequestBean.java | 3 ++ .../phone/JobsPhoneWebApplicationBean.java | 25 ++++++++------ .../JobsUserProfileWebRequestBean.java | 4 ++- .../JobsProfileModeWebApplicationBean.java | 2 ++ .../JobsUserRegisterWebSessionBean.java | 14 ++++---- .../JobsResendLinkWebSessionBean.java | 12 ++++--- .../user/JobsAdminUserWebRequestBean.java | 2 ++ .../beans/user/JobsUserWebSessionBean.java | 4 ++- .../JobsUserPasswordWebRequestBean.java | 4 ++- 27 files changed, 127 insertions(+), 55 deletions(-) rename src/java/org/mxchange/jjobs/beans/login/{ => user}/JobsUserLoginWebSessionBean.java (99%) rename src/java/org/mxchange/jjobs/beans/login/{ => user}/JobsUserLoginWebSessionController.java (98%) diff --git a/src/java/org/mxchange/jjobs/beans/BaseJobsController.java b/src/java/org/mxchange/jjobs/beans/BaseJobsController.java index 03acfab3..7cbbacd4 100644 --- a/src/java/org/mxchange/jjobs/beans/BaseJobsController.java +++ b/src/java/org/mxchange/jjobs/beans/BaseJobsController.java @@ -38,6 +38,12 @@ public abstract class BaseJobsController implements Serializable { */ private static final long serialVersionUID = 50_837_597_127_567_140L; + /** + * Protected constructor + */ + protected BaseJobsController () { + } + /** * Determines principal's name or returns null if no principal (security) is * set. diff --git a/src/java/org/mxchange/jjobs/beans/addressbook/JobsAddressbookWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/addressbook/JobsAddressbookWebSessionBean.java index cd9fb585..7bf277ac 100644 --- a/src/java/org/mxchange/jjobs/beans/addressbook/JobsAddressbookWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/addressbook/JobsAddressbookWebSessionBean.java @@ -35,16 +35,16 @@ import javax.naming.InitialContext; import javax.naming.NamingException; import org.mxchange.addressbook.model.addressbook.AddressbookSessionBeanRemote; import org.mxchange.jaddressbookcore.events.addressbook.AddressbookLoadedEvent; +import org.mxchange.jaddressbookcore.events.addressbook.ObservableAddressbookLoadedEvent; import org.mxchange.jaddressbookcore.exceptions.AddressbookNameAlreadyUsedException; import org.mxchange.jaddressbookcore.exceptions.AddressbookNotFoundException; import org.mxchange.jaddressbookcore.model.addressbook.Addressbook; import org.mxchange.jaddressbookcore.model.addressbook.UserAddressbook; import org.mxchange.jaddressbookcore.model.addressbook.entry.AddressbookEntry; import org.mxchange.jjobs.beans.BaseJobsController; -import org.mxchange.jjobs.beans.login.JobsUserLoginWebSessionController; -import org.mxchange.jusercore.model.user.User; -import org.mxchange.jaddressbookcore.events.addressbook.ObservableAddressbookLoadedEvent; +import org.mxchange.jjobs.beans.login.user.JobsUserLoginWebSessionController; import org.mxchange.jusercore.events.login.ObservableUserLoggedInEvent; +import org.mxchange.jusercore.model.user.User; /** * An address book bean (controller) @@ -112,17 +112,8 @@ public class JobsAddressbookWebSessionBean extends BaseJobsController implements * Default constructor */ public JobsAddressbookWebSessionBean () { - // Try it - try { - // Get initial context - Context context = new InitialContext(); - - // Try to lookup - this.addressbookBean = (AddressbookSessionBeanRemote) context.lookup("java:global/jjobs-ejb/jjobs-adr!org.mxchange.jjobs.model.addressbook.JobsAddressbookSessionBeanRemote"); //NOI18N - } catch (final NamingException e) { - // Throw again - throw new FaceletException(e); - } + // Call super constructor + super(); } @Override @@ -315,6 +306,18 @@ public class JobsAddressbookWebSessionBean extends BaseJobsController implements */ @PostConstruct public void init () { + // Try it + try { + // Get initial context + Context context = new InitialContext(); + + // Try to lookup + this.addressbookBean = (AddressbookSessionBeanRemote) context.lookup("java:global/jjobs-ejb/jjobs-adr!org.mxchange.jjobs.model.addressbook.JobsAddressbookSessionBeanRemote"); //NOI18N + } catch (final NamingException e) { + // Throw again + throw new FaceletException(e); + } + // Init list this.usersAddressbooks = new LinkedList<>(); @@ -424,4 +427,5 @@ public class JobsAddressbookWebSessionBean extends BaseJobsController implements // Fill list with entries this.usersAddressbooks = this.addressbookBean.getUsersAddressbookList(user); } + } diff --git a/src/java/org/mxchange/jjobs/beans/confirmlink/JobsConfirmationLinkWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/confirmlink/JobsConfirmationLinkWebRequestBean.java index 6ed77d52..cdabd780 100644 --- a/src/java/org/mxchange/jjobs/beans/confirmlink/JobsConfirmationLinkWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/confirmlink/JobsConfirmationLinkWebRequestBean.java @@ -89,6 +89,8 @@ public class JobsConfirmationLinkWebRequestBean extends BaseJobsController imple * Default constructor */ public JobsConfirmationLinkWebRequestBean () { + // Call super constructor + super(); } @Override diff --git a/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java index 9ffc2b85..86afccbe 100644 --- a/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java @@ -254,6 +254,8 @@ public class JobsAdminContactWebRequestBean extends BaseJobsController implement * Default constructor */ public JobsAdminContactWebRequestBean () { + // Call super constructor + super(); } @Override diff --git a/src/java/org/mxchange/jjobs/beans/contact/JobsContactWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/contact/JobsContactWebSessionBean.java index ccde6746..abbaea24 100644 --- a/src/java/org/mxchange/jjobs/beans/contact/JobsContactWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/contact/JobsContactWebSessionBean.java @@ -42,7 +42,7 @@ import org.mxchange.jcontacts.events.contact.update.ObservableAdminUpdatedContac import org.mxchange.jcontacts.exceptions.ContactNotFoundException; import org.mxchange.jcountry.data.Country; import org.mxchange.jjobs.beans.BaseJobsController; -import org.mxchange.jjobs.beans.login.JobsUserLoginWebSessionController; +import org.mxchange.jjobs.beans.login.user.JobsUserLoginWebSessionController; import org.mxchange.jjobs.beans.user.JobsUserWebSessionController; import org.mxchange.jphone.phonenumbers.fax.DialableFaxNumber; import org.mxchange.jphone.phonenumbers.fax.FaxNumber; @@ -234,6 +234,9 @@ public class JobsContactWebSessionBean extends BaseJobsController implements Job * Default constructor */ public JobsContactWebSessionBean () { + // Call super constructor + super(); + // Init lists/maps this.contactList = new LinkedList<>(); this.emailAddressList = new LinkedList<>(); diff --git a/src/java/org/mxchange/jjobs/beans/contact/phone/JobsAdminContactPhoneWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/contact/phone/JobsAdminContactPhoneWebRequestBean.java index d0a8d190..8e82d443 100644 --- a/src/java/org/mxchange/jjobs/beans/contact/phone/JobsAdminContactPhoneWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/contact/phone/JobsAdminContactPhoneWebRequestBean.java @@ -17,6 +17,7 @@ package org.mxchange.jjobs.beans.contact.phone; import java.text.MessageFormat; +import javax.annotation.PostConstruct; import javax.enterprise.context.RequestScoped; import javax.enterprise.event.Event; import javax.enterprise.event.Observes; @@ -140,20 +141,11 @@ public class JobsAdminContactPhoneWebRequestBean extends BaseJobsController impl * Default constructor */ public JobsAdminContactPhoneWebRequestBean () { + // Call super constructor + super(); + // String caller = MessageFormat.format("{0}.{1}", Thread.currentThread().getStackTrace()[3].getClassName(), Thread.currentThread().getStackTrace()[3].getMethodName()); // System.out.println(MessageFormat.format("{0}: Constructed, caller: {1}", this.getClass().getSimpleName(), caller)); - - // Try it - try { - // Get initial context - Context context = new InitialContext(); - - // Try to lookup the beans - this.adminPhoneBean = (AdminContactsPhoneSessionBeanRemote) context.lookup("java:global/jjobs-ejb/adminContactPhone!org.mxchange.jcontacts.phone.AdminContactsPhoneSessionBeanRemote"); //NOI18N - } catch (final NamingException e) { - // Throw again - throw new FaceletException(e); - } } /** @@ -414,6 +406,24 @@ public class JobsAdminContactPhoneWebRequestBean extends BaseJobsController impl return "admin_show_contact"; //NOI18N } + /** + * Post-construction method + */ + @PostConstruct + public void init () { + // Try it + try { + // Get initial context + Context context = new InitialContext(); + + // Try to lookup the beans + this.adminPhoneBean = (AdminContactsPhoneSessionBeanRemote) context.lookup("java:global/jjobs-ejb/adminContactPhone!org.mxchange.jcontacts.phone.AdminContactsPhoneSessionBeanRemote"); //NOI18N + } catch (final NamingException e) { + // Throw again + throw new FaceletException(e); + } + } + @Override public String unlinkFaxContactData () { // Is all data set diff --git a/src/java/org/mxchange/jjobs/beans/contact/phone/JobsContactPhoneWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/contact/phone/JobsContactPhoneWebSessionBean.java index ee524e2b..8390f8c4 100644 --- a/src/java/org/mxchange/jjobs/beans/contact/phone/JobsContactPhoneWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/contact/phone/JobsContactPhoneWebSessionBean.java @@ -78,6 +78,9 @@ public class JobsContactPhoneWebSessionBean extends BaseJobsController implement * Default constructor */ public JobsContactPhoneWebSessionBean () { + // Call super constructor + super(); + // Init lists/maps this.contacts = new HashMap<>(10); } diff --git a/src/java/org/mxchange/jjobs/beans/country/JobsAdminCountryWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/country/JobsAdminCountryWebRequestBean.java index af393e61..3d6314a8 100644 --- a/src/java/org/mxchange/jjobs/beans/country/JobsAdminCountryWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/country/JobsAdminCountryWebRequestBean.java @@ -103,6 +103,8 @@ public class JobsAdminCountryWebRequestBean extends BaseJobsController implement * Default constructor */ public JobsAdminCountryWebRequestBean () { + // Call super constructor + super(); } @Override diff --git a/src/java/org/mxchange/jjobs/beans/country/JobsCountryWebApplicationBean.java b/src/java/org/mxchange/jjobs/beans/country/JobsCountryWebApplicationBean.java index 7fd86a2b..b7ae7e40 100644 --- a/src/java/org/mxchange/jjobs/beans/country/JobsCountryWebApplicationBean.java +++ b/src/java/org/mxchange/jjobs/beans/country/JobsCountryWebApplicationBean.java @@ -59,6 +59,8 @@ public class JobsCountryWebApplicationBean extends BaseJobsController implements * Default constructor */ public JobsCountryWebApplicationBean () { + // Call super constructor + super(); } /** diff --git a/src/java/org/mxchange/jjobs/beans/email_address/JobsEmailChangeWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/email_address/JobsEmailChangeWebSessionBean.java index 41f1520b..cca1199a 100644 --- a/src/java/org/mxchange/jjobs/beans/email_address/JobsEmailChangeWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/email_address/JobsEmailChangeWebSessionBean.java @@ -31,7 +31,7 @@ import org.mxchange.jcontacts.contact.Contact; import org.mxchange.jcoreee.utils.FacesUtils; import org.mxchange.jjobs.beans.BaseJobsController; import org.mxchange.jjobs.beans.features.JobsFeaturesWebApplicationController; -import org.mxchange.jjobs.beans.login.JobsUserLoginWebSessionController; +import org.mxchange.jjobs.beans.login.user.JobsUserLoginWebSessionController; import org.mxchange.jusercore.exceptions.UserPasswordMismatchException; import org.mxchange.jusercore.model.email_address.ChangeableEmailAddress; import org.mxchange.jusercore.model.email_address.EmailAddressChange; @@ -88,6 +88,8 @@ public class JobsEmailChangeWebSessionBean extends BaseJobsController implements * Default constructor */ public JobsEmailChangeWebSessionBean () { + // Call super constructor + super(); } @Override diff --git a/src/java/org/mxchange/jjobs/beans/features/JobsFeatureWebApplicationBean.java b/src/java/org/mxchange/jjobs/beans/features/JobsFeatureWebApplicationBean.java index ab2e88ab..d0bc78b3 100644 --- a/src/java/org/mxchange/jjobs/beans/features/JobsFeatureWebApplicationBean.java +++ b/src/java/org/mxchange/jjobs/beans/features/JobsFeatureWebApplicationBean.java @@ -39,6 +39,8 @@ public class JobsFeatureWebApplicationBean extends BaseJobsController implements * Default constructor */ public JobsFeatureWebApplicationBean () { + // Call super constructor + super(); } /** diff --git a/src/java/org/mxchange/jjobs/beans/gender/JobsGenderWebApplicationBean.java b/src/java/org/mxchange/jjobs/beans/gender/JobsGenderWebApplicationBean.java index 0b254a28..58fe20cb 100644 --- a/src/java/org/mxchange/jjobs/beans/gender/JobsGenderWebApplicationBean.java +++ b/src/java/org/mxchange/jjobs/beans/gender/JobsGenderWebApplicationBean.java @@ -42,6 +42,8 @@ public class JobsGenderWebApplicationBean extends BaseJobsController implements * Default constructor */ public JobsGenderWebApplicationBean () { + // Call super constructor + super(); } @Override diff --git a/src/java/org/mxchange/jjobs/beans/helper/JobsWebRequestHelperBean.java b/src/java/org/mxchange/jjobs/beans/helper/JobsWebRequestHelperBean.java index 4079e115..f6b7b1e3 100644 --- a/src/java/org/mxchange/jjobs/beans/helper/JobsWebRequestHelperBean.java +++ b/src/java/org/mxchange/jjobs/beans/helper/JobsWebRequestHelperBean.java @@ -103,6 +103,9 @@ public class JobsWebRequestHelperBean extends BaseJobsController implements Jobs * Default constructor */ public JobsWebRequestHelperBean () { + // Call super constructor + super(); + // String caller = MessageFormat.format("{0}.{1}", Thread.currentThread().getStackTrace()[3].getClassName(), Thread.currentThread().getStackTrace()[3].getMethodName()); // System.out.println(MessageFormat.format("{0}: Constructed, caller: {1}", this.getClass().getSimpleName(), caller)); } diff --git a/src/java/org/mxchange/jjobs/beans/localization/JobsLocalizationSessionBean.java b/src/java/org/mxchange/jjobs/beans/localization/JobsLocalizationSessionBean.java index 57b1d047..9b35a04c 100644 --- a/src/java/org/mxchange/jjobs/beans/localization/JobsLocalizationSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/localization/JobsLocalizationSessionBean.java @@ -53,6 +53,8 @@ public class JobsLocalizationSessionBean extends BaseJobsController implements J * Default constructor */ public JobsLocalizationSessionBean () { + // Call super constructor + super(); } /** diff --git a/src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/login/user/JobsUserLoginWebSessionBean.java similarity index 99% rename from src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionBean.java rename to src/java/org/mxchange/jjobs/beans/login/user/JobsUserLoginWebSessionBean.java index 6f11c04b..a3cb9d97 100644 --- a/src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/login/user/JobsUserLoginWebSessionBean.java @@ -14,7 +14,7 @@ * You should have received a copy of the GNU Affero General Public License * along with this program. If not, see . */ -package org.mxchange.jjobs.beans.login; +package org.mxchange.jjobs.beans.login.user; import java.text.MessageFormat; import java.util.Collections; @@ -144,6 +144,9 @@ public class JobsUserLoginWebSessionBean extends BaseJobsController implements J * Default constructor */ public JobsUserLoginWebSessionBean () { + // Call super constructor + super(); + // Defaul template is guest this.baseTemplatePathName = GUEST_BASE_TEMPLATE_NAME; } diff --git a/src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionController.java b/src/java/org/mxchange/jjobs/beans/login/user/JobsUserLoginWebSessionController.java similarity index 98% rename from src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionController.java rename to src/java/org/mxchange/jjobs/beans/login/user/JobsUserLoginWebSessionController.java index 467c505a..bd619337 100644 --- a/src/java/org/mxchange/jjobs/beans/login/JobsUserLoginWebSessionController.java +++ b/src/java/org/mxchange/jjobs/beans/login/user/JobsUserLoginWebSessionController.java @@ -14,7 +14,7 @@ * You should have received a copy of the GNU Affero General Public License * along with this program. If not, see . */ -package org.mxchange.jjobs.beans.login; +package org.mxchange.jjobs.beans.login.user; import java.io.Serializable; import java.util.List; diff --git a/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsAdminMobileProviderWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsAdminMobileProviderWebRequestBean.java index bc7c8c47..90184036 100644 --- a/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsAdminMobileProviderWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsAdminMobileProviderWebRequestBean.java @@ -94,6 +94,8 @@ public class JobsAdminMobileProviderWebRequestBean extends BaseJobsController im * Default constructor */ public JobsAdminMobileProviderWebRequestBean () { + // Call super constructor + super(); } @Override diff --git a/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsMobileProviderWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsMobileProviderWebRequestBean.java index e47377ce..f161c5cd 100644 --- a/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsMobileProviderWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsMobileProviderWebRequestBean.java @@ -59,6 +59,8 @@ public class JobsMobileProviderWebRequestBean extends BaseJobsController impleme * Default constructor */ public JobsMobileProviderWebRequestBean () { + // Call super constructor + super(); } /** diff --git a/src/java/org/mxchange/jjobs/beans/phone/JobsAdminPhoneWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/phone/JobsAdminPhoneWebRequestBean.java index 387eb8a0..96562704 100644 --- a/src/java/org/mxchange/jjobs/beans/phone/JobsAdminPhoneWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/phone/JobsAdminPhoneWebRequestBean.java @@ -196,6 +196,9 @@ public class JobsAdminPhoneWebRequestBean extends BaseJobsController implements * Default constructor */ public JobsAdminPhoneWebRequestBean () { + // Call super constructor + super(); + // String caller = MessageFormat.format("{0}.{1}", Thread.currentThread().getStackTrace()[3].getClassName(), Thread.currentThread().getStackTrace()[3].getMethodName()); // System.out.println(MessageFormat.format("{0}: Constructed, caller: {1}", this.getClass().getSimpleName(), caller)); } diff --git a/src/java/org/mxchange/jjobs/beans/phone/JobsPhoneWebApplicationBean.java b/src/java/org/mxchange/jjobs/beans/phone/JobsPhoneWebApplicationBean.java index 7c433855..3d14b289 100644 --- a/src/java/org/mxchange/jjobs/beans/phone/JobsPhoneWebApplicationBean.java +++ b/src/java/org/mxchange/jjobs/beans/phone/JobsPhoneWebApplicationBean.java @@ -85,17 +85,8 @@ public class JobsPhoneWebApplicationBean extends BaseJobsController implements J * Default constructor */ public JobsPhoneWebApplicationBean () { - // Try it - try { - // Get initial context - Context context = new InitialContext(); - - // Try to lookup the beans - this.phoneBean = (PhoneSessionBeanRemote) context.lookup("java:global/jjobs-ejb/phone!org.mxchange.jphone.phonenumbers.phone.PhoneSessionBeanRemote"); //NOI18N - } catch (final NamingException e) { - // Throw it again - throw new FaceletException(e); - } + // Call super constructor + super(); // Init all lists this.mobileNumbers = new LinkedList<>(); @@ -450,6 +441,18 @@ public class JobsPhoneWebApplicationBean extends BaseJobsController implements J */ @PostConstruct public void init () { + // Try it + try { + // Get initial context + Context context = new InitialContext(); + + // Try to lookup the beans + this.phoneBean = (PhoneSessionBeanRemote) context.lookup("java:global/jjobs-ejb/phone!org.mxchange.jphone.phonenumbers.phone.PhoneSessionBeanRemote"); //NOI18N + } catch (final NamingException e) { + // Throw it again + throw new FaceletException(e); + } + // All phone numbers this.allMobileNumbers().addAll(this.phoneBean.allMobileNumbers()); this.allFaxNumbers().addAll(this.phoneBean.allFaxNumbers()); diff --git a/src/java/org/mxchange/jjobs/beans/profile/JobsUserProfileWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/profile/JobsUserProfileWebRequestBean.java index 34bb6c51..5d4ffe76 100644 --- a/src/java/org/mxchange/jjobs/beans/profile/JobsUserProfileWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/profile/JobsUserProfileWebRequestBean.java @@ -23,7 +23,7 @@ import javax.faces.view.facelets.FaceletException; import javax.inject.Inject; import javax.inject.Named; import org.mxchange.jjobs.beans.BaseJobsController; -import org.mxchange.jjobs.beans.login.JobsUserLoginWebSessionController; +import org.mxchange.jjobs.beans.login.user.JobsUserLoginWebSessionController; import org.mxchange.jjobs.beans.user.JobsUserWebSessionController; import org.mxchange.jusercore.exceptions.UserNotFoundException; import org.mxchange.jusercore.model.user.User; @@ -59,6 +59,8 @@ public class JobsUserProfileWebRequestBean extends BaseJobsController implements * Default constructor */ public JobsUserProfileWebRequestBean () { + // Call super constructor + super(); } /** diff --git a/src/java/org/mxchange/jjobs/beans/profilemode/JobsProfileModeWebApplicationBean.java b/src/java/org/mxchange/jjobs/beans/profilemode/JobsProfileModeWebApplicationBean.java index 524699bd..1bbc7df1 100644 --- a/src/java/org/mxchange/jjobs/beans/profilemode/JobsProfileModeWebApplicationBean.java +++ b/src/java/org/mxchange/jjobs/beans/profilemode/JobsProfileModeWebApplicationBean.java @@ -40,6 +40,8 @@ public class JobsProfileModeWebApplicationBean extends BaseJobsController implem * Default constructor */ public JobsProfileModeWebApplicationBean () { + // Call super constructor + super(); } @Override diff --git a/src/java/org/mxchange/jjobs/beans/register/JobsUserRegisterWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/register/JobsUserRegisterWebSessionBean.java index f99ba705..cfd96b36 100644 --- a/src/java/org/mxchange/jjobs/beans/register/JobsUserRegisterWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/register/JobsUserRegisterWebSessionBean.java @@ -83,22 +83,24 @@ public class JobsUserRegisterWebSessionBean extends BaseJobsController implement private UserRegistrationSessionBeanRemote registerBean; /** - * An en event fireable when a new user has registered + * User controller */ @Inject - @Any - private Event registeredEvent; + private JobsUserWebSessionController userController; /** - * User controller + * An en event fireable when a new user has registered */ @Inject - private JobsUserWebSessionController userController; + @Any + private Event userRegisteredEvent; /** * Default constructor */ public JobsUserRegisterWebSessionBean () { + // Call super constructor + super(); } @Override @@ -191,7 +193,7 @@ public class JobsUserRegisterWebSessionBean extends BaseJobsController implement assert (registeredUser.getUserId() instanceof Long) : "registeredUser.userId is null after registerUser() was called."; //NOI18N // Fire event - this.registeredEvent.fire(new UserRegisteredEvent(registeredUser)); + this.userRegisteredEvent.fire(new UserRegisteredEvent(registeredUser)); // All fine, redirect to proper page return "user_register_done"; //NOI18N diff --git a/src/java/org/mxchange/jjobs/beans/resendlink/JobsResendLinkWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/resendlink/JobsResendLinkWebSessionBean.java index ed028b37..31830744 100644 --- a/src/java/org/mxchange/jjobs/beans/resendlink/JobsResendLinkWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/resendlink/JobsResendLinkWebSessionBean.java @@ -58,17 +58,17 @@ public class JobsResendLinkWebSessionBean extends BaseJobsController implements */ private String emailAddress; - /** - * EJB for resending confirmation link - */ - private ResendLinkSessionBeanRemote resendLinkBean; - /** * Localization controller */ @Inject private JobsLocalizationSessionController localizationController; + /** + * EJB for resending confirmation link + */ + private ResendLinkSessionBeanRemote resendLinkBean; + /** * Regular user controller */ @@ -86,6 +86,8 @@ public class JobsResendLinkWebSessionBean extends BaseJobsController implements * Default constructor */ public JobsResendLinkWebSessionBean () { + // Call super constructor + super(); } @Override diff --git a/src/java/org/mxchange/jjobs/beans/user/JobsAdminUserWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/user/JobsAdminUserWebRequestBean.java index a8f992fb..41840a09 100644 --- a/src/java/org/mxchange/jjobs/beans/user/JobsAdminUserWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/user/JobsAdminUserWebRequestBean.java @@ -197,6 +197,8 @@ public class JobsAdminUserWebRequestBean extends BaseJobsController implements J * Default constructor */ public JobsAdminUserWebRequestBean () { + // Call super constructor + super(); } @Override diff --git a/src/java/org/mxchange/jjobs/beans/user/JobsUserWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/user/JobsUserWebSessionBean.java index e9817e6c..bcdb7a98 100644 --- a/src/java/org/mxchange/jjobs/beans/user/JobsUserWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/user/JobsUserWebSessionBean.java @@ -36,7 +36,7 @@ import org.mxchange.jcontacts.contact.Contact; import org.mxchange.jjobs.beans.BaseJobsController; import org.mxchange.jjobs.beans.contact.JobsContactWebSessionController; import org.mxchange.jjobs.beans.features.JobsFeaturesWebApplicationController; -import org.mxchange.jjobs.beans.login.JobsUserLoginWebSessionController; +import org.mxchange.jjobs.beans.login.user.JobsUserLoginWebSessionController; import org.mxchange.jusercore.events.confirmation.ObservableUserConfirmedAccountEvent; import org.mxchange.jusercore.events.login.ObservableUserLoggedInEvent; import org.mxchange.jusercore.events.registration.ObservableUserRegisteredEvent; @@ -149,6 +149,8 @@ public class JobsUserWebSessionBean extends BaseJobsController implements JobsUs * Default constructor */ public JobsUserWebSessionBean () { + // Call super constructor + super(); } /** diff --git a/src/java/org/mxchange/jjobs/beans/user/password/JobsUserPasswordWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/user/password/JobsUserPasswordWebRequestBean.java index 7aeadf35..80bc5a97 100644 --- a/src/java/org/mxchange/jjobs/beans/user/password/JobsUserPasswordWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/user/password/JobsUserPasswordWebRequestBean.java @@ -30,7 +30,7 @@ import javax.naming.NamingException; import org.mxchange.jcoreee.utils.FacesUtils; import org.mxchange.jjobs.beans.BaseJobsController; import org.mxchange.jjobs.beans.features.JobsFeaturesWebApplicationController; -import org.mxchange.jjobs.beans.login.JobsUserLoginWebSessionController; +import org.mxchange.jjobs.beans.login.user.JobsUserLoginWebSessionController; import org.mxchange.jusercore.events.user.password_change.ObservableUpdatedUserPasswordEvent; import org.mxchange.jusercore.events.user.password_change.UpdatedUserPasswordEvent; import org.mxchange.jusercore.exceptions.UserNotFoundException; @@ -99,6 +99,8 @@ public class JobsUserPasswordWebRequestBean extends BaseJobsController implement * Default constructor */ public JobsUserPasswordWebRequestBean () { + // Call super constructor + super(); } @Override -- 2.39.5