]> git.mxchange.org Git - jfinancials-war.git/commitdiff
very noisy debug lines commented out
authorRoland Haeder <roland@mxchange.org>
Fri, 15 Apr 2016 18:23:45 +0000 (20:23 +0200)
committerRoland Haeder <roland@mxchange.org>
Fri, 15 Apr 2016 18:24:52 +0000 (20:24 +0200)
Signed-off-by: Roland Häder <roland@mxchange.org>
src/java/org/mxchange/addressbook/converter/country/AddressbookCountryConverter.java
src/java/org/mxchange/addressbook/converter/mobileprovider/AddressbookMobileProviderConverter.java
src/java/org/mxchange/addressbook/converter/user/AddressbookUserConverter.java

index 6e49447c7ade844c3820d5ab289a094a434b3e70..ee368cd470564c1a9161368b0d9d42fdd5e02004 100644 (file)
@@ -73,12 +73,12 @@ public class AddressbookCountryConverter implements Converter {
        @Override
        public Object getAsObject (final FacesContext context, final UIComponent component, final String submittedValue) {
                // Trace message
-               this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: context={0},component={1},submittedValue={2},this.countryBean={3} - CALLED!", context, component, submittedValue, this.countryBean)); //NOI18N
+               // NOISY-DEBUG: this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: context={0},component={1},submittedValue={2},this.countryBean={3} - CALLED!", context, component, submittedValue, this.countryBean)); //NOI18N
 
                // Is the value null or empty?
                if ((null == submittedValue) || (submittedValue.trim().isEmpty())) {
-                       // Trace message
-                       this.loggerBeanLocal.logTrace("getAsObject: submittedValue is null or empty - EXIT!"); //NOI18N
+                       // Warning message
+                       this.loggerBeanLocal.logWarning("getAsObject: submittedValue is null or empty - EXIT!"); //NOI18N
 
                        // Return null
                        return null;
@@ -99,7 +99,7 @@ public class AddressbookCountryConverter implements Converter {
                        assert (countryId > 0) : "countryId is smaller than one: " + countryId; //NOI18N
 
                        // Debug message
-                       this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: countryId={0}", countryId)); //NOI18N
+                       // NOISY-DEBUG: this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: countryId={0}", countryId)); //NOI18N
 
                        // Try to find it
                        for (final Country cntry : countryList) {
@@ -116,7 +116,7 @@ public class AddressbookCountryConverter implements Converter {
                }
 
                // Trace message
-               this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: country={0} - EXIT!", country)); //NOI18N
+               // NOISY-DEBUG: this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: country={0} - EXIT!", country)); //NOI18N
 
                // Return it
                return country;
index f2a7989c4f3f3d77979ff9a755ee0993cd3789f0..cd254cfd7cf50551e9ac30c8742e51b399487f73 100644 (file)
@@ -73,12 +73,12 @@ public class AddressbookMobileProviderConverter implements Converter {
        @Override
        public Object getAsObject (final FacesContext context, final UIComponent component, final String submittedValue) {
                // Trace message
-               this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: context={0},component={1},submittedValue={2} - CALLED!", context, component, submittedValue)); //NOI18N
+               // NOISY-DEBUG: this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: context={0},component={1},submittedValue={2} - CALLED!", context, component, submittedValue)); //NOI18N
 
                // Is the value null or empty?
                if ((null == submittedValue) || (submittedValue.trim().isEmpty())) {
-                       // Trace message
-                       this.loggerBeanLocal.logTrace("getAsObject: submittedValue is null or empty - EXIT!"); //NOI18N
+                       // Warning message
+                       this.loggerBeanLocal.logWarning("getAsObject: submittedValue is null or empty - EXIT!"); //NOI18N
 
                        // Return null
                        return null;
@@ -99,7 +99,7 @@ public class AddressbookMobileProviderConverter implements Converter {
                        assert (providerId > 0) : "providerId is smaller than one: " + providerId; //NOI18N
 
                        // Debug message
-                       this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: providerId={0}", providerId)); //NOI18N
+                       // NOISY-DEBUG: this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: providerId={0}", providerId)); //NOI18N
 
                        // Try to find it
                        for (final MobileProvider prov : providerList) {
@@ -116,7 +116,7 @@ public class AddressbookMobileProviderConverter implements Converter {
                }
 
                // Trace message
-               this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: provider={0} - EXIT!", provider)); //NOI18N
+               // NOISY-DEBUG: this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: provider={0} - EXIT!", provider)); //NOI18N
 
                // Return it
                return provider;
index 95dba66c73a5ce32db0b93a0a06c61c2771c0c15..7e559db1bb2eb144cbecc1203ae856986b690c05 100644 (file)
@@ -29,7 +29,7 @@ import org.mxchange.jcoreeelogger.beans.local.logger.Log;
 import org.mxchange.jcoreeelogger.beans.local.logger.LoggerBeanLocal;
 import org.mxchange.jusercore.exceptions.UserNotFoundException;
 import org.mxchange.jusercore.model.user.User;
-import org.mxchange.addressbook.beans.user.AddressbookUserWebSessionController;
+import org.mxchange.jusercore.model.user.UserSessionBeanRemote;
 
 /**
  * Converter for user id <-> valid user instance
@@ -46,9 +46,9 @@ public class AddressbookUserConverter implements Converter {
        private LoggerBeanLocal loggerBeanLocal;
 
        /**
-        * User bean
+        * User EJB
         */
-       private AddressbookUserWebSessionController userController;
+       private UserSessionBeanRemote userBean;
 
        /**
         * Initialization of this converter
@@ -63,7 +63,7 @@ public class AddressbookUserConverter implements Converter {
                        this.loggerBeanLocal = (LoggerBeanLocal) context.lookup("java:global/jcore-logger-ejb/logger!org.mxchange.jcoreeelogger.beans.local.logger.LoggerBeanLocal"); //NOI18N
 
                        // ... and user controller
-                       this.userController = (AddressbookUserWebSessionController) context.lookup("java:global/addressbook-ejb/user!org.mxchange.jusercore.model.user.UserSessionBeanRemote"); //NOI18N
+                       this.userBean = (UserSessionBeanRemote) context.lookup("java:global/addressbook-ejb/user!org.mxchange.jusercore.model.user.UserSessionBeanRemote"); //NOI18N
                } catch (final NamingException ex) {
                        // Continue to throw it
                        throw new RuntimeException(MessageFormat.format("context.lookup() failed: {0}", ex.getMessage()), ex); //NOI18N
@@ -73,12 +73,12 @@ public class AddressbookUserConverter implements Converter {
        @Override
        public Object getAsObject (final FacesContext context, final UIComponent component, final String submittedValue) {
                // Trace message
-               this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: context={0},component={1},submittedValue={2} - CALLED!", context, component, submittedValue)); //NOI18N
+               // NOISY-DEBUG: this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: context={0},component={1},submittedValue={2} - CALLED!", context, component, submittedValue)); //NOI18N
 
                // Is the value null or empty?
                if ((null == submittedValue) || (submittedValue.trim().isEmpty())) {
-                       // Trace message
-                       this.loggerBeanLocal.logTrace("getAsObject: submittedValue is null or empty - EXIT!"); //NOI18N
+                       // Warning message
+                       this.loggerBeanLocal.logWarning("getAsObject: submittedValue is null or empty - EXIT!"); //NOI18N
 
                        // Return null
                        return null;
@@ -92,26 +92,23 @@ public class AddressbookUserConverter implements Converter {
                        Long userId = Long.valueOf(submittedValue);
 
                        // Debug message
-                       this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: userId{0}", userId));
+                       // NOISY-DEBUG: this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: userId{0}", userId)); //NOI18N
 
                        // Try to get user instance from it
-                       user = this.userController.lookupUserById(userId);
+                       user = this.userBean.findUserById(userId);
 
                        // Debug message
-                       this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: user={0}", user));
+                       // NOISY-DEBUG: this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: user={0}", user)); //NOI18N
                } catch (final NumberFormatException ex) {
                        // Throw again
                        throw new ConverterException(ex);
                } catch (final UserNotFoundException ex) {
                        // Debug message
-                       this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: Exception: {0} - Returning null ...", ex));
-
-                       // Return null
-                       return null;
+                       this.loggerBeanLocal.logDebug(MessageFormat.format("getAsObject: Exception: {0} - Returning null ...", ex)); //NOI18N
                }
 
                // Trace message
-               this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: user={0} - EXIT!", user));
+               // NOISY-DEBUG: this.loggerBeanLocal.logTrace(MessageFormat.format("getAsObject: user={0} - EXIT!", user)); //NOI18N
 
                // Return it
                return user;