]> git.mxchange.org Git - jjobs-war.git/commitdiff
introduced method showFacesMessage() with 2nd parameter being a message string (pleas...
authorRoland Häder <roland@mxchange.org>
Thu, 21 Jul 2016 16:04:04 +0000 (18:04 +0200)
committerRoland Haeder <roland@mxchange.org>
Sun, 7 Aug 2016 10:31:59 +0000 (12:31 +0200)
src/java/org/mxchange/jjobs/beans/BaseJobsController.java

index 2ebed1c21ac1f112dd3737e5a5434e5bc633542e..89cfd8ee006888706bf68677fc95a8bbc3f29e9b 100644 (file)
@@ -113,7 +113,18 @@ public abstract class BaseJobsController implements Serializable {
                System.out.println(MessageFormat.format("showFacesMessage: clientId={0},cause={1} - CALLED!", clientId, cause));
 
                // Get context and add message
-               FacesContext.getCurrentInstance().addMessage(clientId, new FacesMessage(cause.getMessage()));
+               this.showFacesMessage(clientId, cause.getMessage());
+       }
+
+       /**
+        * Shows a faces message with given message.
+        * <p>
+        * @param clientId Client id to send message to
+        * @param message Causing exception
+        */
+       protected void showFacesMessage (final String clientId, final String message) {
+               // Get context and add message
+               FacesContext.getCurrentInstance().addMessage(clientId, new FacesMessage(message));
        }
 
 }