]> git.mxchange.org Git - jjobs-mailer-ejb.git/commitdiff
added business method allUsers() + updated jar(s)
authorRoland Haeder <roland@mxchange.org>
Sun, 10 Apr 2016 17:35:43 +0000 (19:35 +0200)
committerRoland Haeder <roland@mxchange.org>
Sun, 10 Apr 2016 17:42:30 +0000 (19:42 +0200)
Signed-off-by: Roland Häder <roland@mxchange.org>
src/java/org/mxchange/jusercore/model/user/AddressbookUserSessionBean.java

index 17d24986b6660548cb1581af331d5033f48377e9..ac39ca111ff5f85d40cf8c83afab281d06117871 100644 (file)
@@ -98,6 +98,25 @@ public class AddressbookUserSessionBean extends BaseDatabaseBean implements User
                return users;
        }
 
+       @Override
+       @SuppressWarnings ("unchecked")
+       public List<User> allUsers () {
+               // Trace message
+               this.getLoggerBeanLocal().logTrace("allUsers: CALLED!"); //NOI18N
+
+               // Get named query
+               Query query = this.getEntityManager().createNamedQuery("allUsers", List.class); //NOI18N
+
+               // Get result
+               List<User> users = query.getResultList();
+
+               // Trace message
+               this.getLoggerBeanLocal().logTrace(MessageFormat.format("allUsers: users.size()={0} - EXIT!", users.size())); //NOI18N
+
+               // Return full list
+               return users;
+       }
+
        @Override
        public User fillUserData (final User user) {
                // Trace message