From: Roland Häder Date: Thu, 21 Apr 2016 08:45:09 +0000 (+0200) Subject: Removed all clear() methods in request-scoped beans as it makes no sense to clear... X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=5f5b6c627f0a8e0984987ed7ab0453420c539be9;p=jjobs-war.git Removed all clear() methods in request-scoped beans as it makes no sense to clear them. --- diff --git a/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java index cfb85afa..1e389c79 100644 --- a/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/contact/JobsAdminContactWebRequestBean.java @@ -476,31 +476,4 @@ public class JobsAdminContactWebRequestBean implements JobsAdminContactWebReques public void init () { } - /** - * Clears this bean - */ - private void clear () { - // Clear all - this.setContactId(null); - this.setBirthday(null); - this.setCellphoneCarrier(null); - this.setCellphoneNumber(null); - this.setCity(null); - this.setComment(null); - this.setCountry(null); - this.setEmailAddress(null); - this.setFamilyName(null); - this.setFaxAreaCode(null); - this.setFaxCountry(null); - this.setFaxNumber(null); - this.setFirstName(null); - this.setGender(null); - this.setHouseNumber(null); - this.setPhoneAreaCode(null); - this.setPhoneCountry(null); - this.setPhoneNumber(null); - this.setStreet(null); - this.setZipCode(null); - } - } diff --git a/src/java/org/mxchange/jjobs/beans/country/JobsAdminCountryWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/country/JobsAdminCountryWebRequestBean.java index eed8f3b2..f8441a22 100644 --- a/src/java/org/mxchange/jjobs/beans/country/JobsAdminCountryWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/country/JobsAdminCountryWebRequestBean.java @@ -146,9 +146,6 @@ public class JobsAdminCountryWebRequestBean implements JobsAdminCountryWebReques // Fire event this.addedCountryEvent.fire(new AdminEventCountryAdded(updatedCountry)); - - // Clear bean - this.clear(); } @Override @@ -222,19 +219,6 @@ public class JobsAdminCountryWebRequestBean implements JobsAdminCountryWebReques return (!this.allCountries().isEmpty()); } - /** - * Clears this bean - */ - private void clear () { - // Clear all - this.setCountryAbroadDialPrefix(null); - this.setCountryCode(null); - this.setCountryExternalDialPrefix(null); - this.setCountryI18nKey(null); - this.setCountryIsLocalPrefixRequired(null); - this.setCountryPhoneCode(null); - } - /** * Checks if given country is already added by iterating over the whole list * and try to find it. diff --git a/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsAdminMobileProviderWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsAdminMobileProviderWebRequestBean.java index 5a45722f..55c1808d 100644 --- a/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsAdminMobileProviderWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/mobileprovider/JobsAdminMobileProviderWebRequestBean.java @@ -129,9 +129,6 @@ public class JobsAdminMobileProviderWebRequestBean implements JobsAdminMobilePro // Fire event this.providerAddedEvent.fire(new AdminMobileProviderAddedEvent(updatedProvider)); - - // Clear this bean - this.clear(); } @Override @@ -184,17 +181,6 @@ public class JobsAdminMobileProviderWebRequestBean implements JobsAdminMobilePro return (!this.allMobileProvider().isEmpty()); } - /** - * Clears this bean - */ - private void clear () { - // Clear all fields - this.setProviderCountry(null); - this.setProviderDialPrefix(null); - this.setProviderMailPattern(null); - this.setProviderName(null); - } - /** * Checks whether if the given mobile provider is already created by * checking both dial prefix and country. diff --git a/src/java/org/mxchange/jjobs/beans/phone/JobsAdminContactPhoneWebSessionBean.java b/src/java/org/mxchange/jjobs/beans/phone/JobsAdminContactPhoneWebSessionBean.java index 4f4bfe02..e21d2449 100644 --- a/src/java/org/mxchange/jjobs/beans/phone/JobsAdminContactPhoneWebSessionBean.java +++ b/src/java/org/mxchange/jjobs/beans/phone/JobsAdminContactPhoneWebSessionBean.java @@ -157,15 +157,4 @@ public class JobsAdminContactPhoneWebSessionBean implements JobsAdminContactPhon this.landLine = landLine; } - /** - * Clears this bean - */ - private void clear () { - // Clear all instances - this.setCellPhone(null); - this.setFax(null); - this.setLandLine(null); - this.setContact(null); - } - } diff --git a/src/java/org/mxchange/jjobs/beans/user/JobsAdminUserWebRequestBean.java b/src/java/org/mxchange/jjobs/beans/user/JobsAdminUserWebRequestBean.java index 5e24d13e..4f6c4643 100644 --- a/src/java/org/mxchange/jjobs/beans/user/JobsAdminUserWebRequestBean.java +++ b/src/java/org/mxchange/jjobs/beans/user/JobsAdminUserWebRequestBean.java @@ -183,9 +183,6 @@ public class JobsAdminUserWebRequestBean implements JobsAdminUserWebRequestContr // Add user to local list this.userList.add(updatedUser); - // Clear all - this.clear(); - // Clear contact instance this.contactController.clear(); } @@ -282,16 +279,6 @@ public class JobsAdminUserWebRequestBean implements JobsAdminUserWebRequestContr return user; } - /** - * Clears this bean - */ - private void clear () { - // Clear all - this.setUserName(null); - this.setUserPassword(null); - this.setUserPasswordRepeat(null); - } - /** * Checks if same password is entered and that they are not empty. *