logger.log(Level.INFO, "User Role List: {0}", user.getRolesList().listIterator().next().toString());
return user;
}
private Roles updateRoleEntityRelationship(String rolename, Users user) throws Exception {
Roles role=null;
List<Roles> webUserRoleList = null;
List<Users> roleRelatedUserList = null;
webUserRoleList = DBInitializer.getRoleByID(rolename);
role = (Roles) webUserRoleList.listIterator().next();
roleRelatedUserList = role.getUsersList();
roleRelatedUserList.add(user);
role.setUsersList(roleRelatedUserList);
return role;
}