directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smckin...@apache.org
Subject [2/4] directory-fortress-core git commit: FC-109 - move utils
Date Tue, 02 Jun 2015 17:01:46 GMT
http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/PermDAO.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/PermDAO.java b/src/main/java/org/apache/directory/fortress/core/rbac/PermDAO.java
index 3616f6f..af41db7 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/PermDAO.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/PermDAO.java
@@ -48,6 +48,7 @@ import org.apache.directory.fortress.core.model.Permission;
 import org.apache.directory.fortress.core.model.Role;
 import org.apache.directory.fortress.core.model.Session;
 import org.apache.directory.fortress.core.model.User;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.apache.directory.fortress.core.util.attr.AttrHelper;
 import org.apache.directory.ldap.client.api.LdapConnection;
 import org.apache.directory.fortress.core.CreateException;
@@ -58,7 +59,7 @@ import org.apache.directory.fortress.core.model.ObjectFactory;
 import org.apache.directory.fortress.core.RemoveException;
 import org.apache.directory.fortress.core.UpdateException;
 import org.apache.directory.fortress.core.ldap.ApacheDsDataProvider;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 
 /**
@@ -245,7 +246,7 @@ final class PermDAO extends ApacheDsDataProvider
 
             // props are optional as well:
             //if the props is null don't try to load these attributes
-            if ( VUtil.isNotNullOrEmpty( entity.getProperties() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getProperties() ) )
             {
                 loadProperties( entity.getProperties(), entry, GlobalIds.PROPS );
             }
@@ -304,7 +305,7 @@ final class PermDAO extends ApacheDsDataProvider
                     ModificationOperation.REPLACE_ATTRIBUTE, TYPE, entity.getType() ) );
             }
 
-            if ( VUtil.isNotNullOrEmpty( entity.getProperties() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getProperties() ) )
             {
                 loadProperties( entity.getProperties(), mods, GlobalIds.PROPS, true );
             }
@@ -422,7 +423,7 @@ final class PermDAO extends ApacheDsDataProvider
 
             // props are optional as well:
             //if the props is null don't try to load these attributes
-            if ( VUtil.isNotNullOrEmpty( entity.getProperties() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getProperties() ) )
             {
                 loadProperties( entity.getProperties(), entry, GlobalIds.PROPS );
             }
@@ -958,7 +959,7 @@ final class PermDAO extends ApacheDsDataProvider
         boolean result = false;
         Set<String> userIds = permission.getUsers();
 
-        if ( VUtil.isNotNullOrEmpty( userIds ) && userIds.contains( session.getUserId() ) )
+        if ( ObjUtil.isNotNullOrEmpty( userIds ) && userIds.contains( session.getUserId() ) )
         {
             // user is assigned directly to this permission, no need to look further.
             return true;
@@ -966,7 +967,7 @@ final class PermDAO extends ApacheDsDataProvider
 
         Set<String> roles = permission.getRoles();
 
-        if ( VUtil.isNotNullOrEmpty( roles ) )
+        if ( ObjUtil.isNotNullOrEmpty( roles ) )
         {
             if ( permission.isAdmin() )
             {
@@ -1275,7 +1276,7 @@ final class PermDAO extends ApacheDsDataProvider
                 roles = RoleUtil.getAscendants( role.getName(), role.getContextId() );
             }
 
-            if ( VUtil.isNotNullOrEmpty( roles ) )
+            if ( ObjUtil.isNotNullOrEmpty( roles ) )
             {
                 filterbuf.append( "|(" );
                 filterbuf.append( ROLES );
@@ -1350,7 +1351,7 @@ final class PermDAO extends ApacheDsDataProvider
             filterbuf.append( ")(|" );
             Set<String> roles = RoleUtil.getInheritedRoles( user.getRoles(), user.getContextId() );
 
-            if ( VUtil.isNotNullOrEmpty( roles ) )
+            if ( ObjUtil.isNotNullOrEmpty( roles ) )
             {
                 for ( String uRole : roles )
                 {
@@ -1483,7 +1484,7 @@ final class PermDAO extends ApacheDsDataProvider
             {
                 roles = RoleUtil.getInheritedRoles( session.getRoles(), session.getContextId() );
             }
-            if ( VUtil.isNotNullOrEmpty( roles ) )
+            if ( ObjUtil.isNotNullOrEmpty( roles ) )
             {
                 for ( String uRole : roles )
                 {

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/PermP.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/PermP.java b/src/main/java/org/apache/directory/fortress/core/rbac/PermP.java
index c2f55a7..efadb0f 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/PermP.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/PermP.java
@@ -35,7 +35,8 @@ import org.apache.directory.fortress.core.model.Permission;
 import org.apache.directory.fortress.core.model.Role;
 import org.apache.directory.fortress.core.model.Session;
 import org.apache.directory.fortress.core.model.User;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
+import org.apache.directory.fortress.core.util.ObjUtil;
 
 
 /**
@@ -579,7 +580,7 @@ public final class PermP
             VUtil.description( pOp.getDescription() );
         }
         // Validate Role Grants:
-        if ( VUtil.isNotNullOrEmpty( pOp.getRoles() ) )
+        if ( ObjUtil.isNotNullOrEmpty( pOp.getRoles() ) )
         {
             Set<String> roles = pOp.getRoles();
             if ( pOp.isAdmin() )
@@ -604,7 +605,7 @@ public final class PermP
             }
         }
         // Validate User Grants:
-        if ( VUtil.isNotNullOrEmpty( pOp.getUsers() ) )
+        if ( ObjUtil.isNotNullOrEmpty( pOp.getUsers() ) )
         {
             Set<String> users = pOp.getUsers();
             UserP up = new UserP();

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/PsoUtil.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/PsoUtil.java b/src/main/java/org/apache/directory/fortress/core/rbac/PsoUtil.java
index ebd68db..b4cdcbb 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/PsoUtil.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/PsoUtil.java
@@ -30,13 +30,14 @@ import org.apache.directory.fortress.core.model.Graphable;
 import org.apache.directory.fortress.core.model.Hier;
 import org.apache.directory.fortress.core.model.OrgUnit;
 import org.apache.directory.fortress.core.model.Relationship;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.jgrapht.graph.SimpleDirectedGraph;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.apache.directory.fortress.core.GlobalIds;
 import org.apache.directory.fortress.core.SecurityException;
 import org.apache.directory.fortress.core.ValidationException;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 import org.apache.directory.fortress.core.util.cache.Cache;
 import org.apache.directory.fortress.core.util.cache.CacheMgr;
 
@@ -157,7 +158,7 @@ public final class PsoUtil
     {
         // create Set with case insensitive comparator:
         Set<String> iOUs = new TreeSet<>( String.CASE_INSENSITIVE_ORDER );
-        if ( VUtil.isNotNullOrEmpty( ous ) )
+        if ( ObjUtil.isNotNullOrEmpty( ous ) )
         {
             for ( OrgUnit ou : ous )
             {
@@ -165,7 +166,7 @@ public final class PsoUtil
                 iOUs.add( name );
                 Set<String> parents = HierUtil.getAscendants( name, getGraph( contextId ) );
 
-                if ( VUtil.isNotNullOrEmpty( parents ) )
+                if ( ObjUtil.isNotNullOrEmpty( parents ) )
                 {
                     iOUs.addAll( parents );
                 }

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/PwPolicyMgrImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/PwPolicyMgrImpl.java b/src/main/java/org/apache/directory/fortress/core/rbac/PwPolicyMgrImpl.java
index de22afa..e14c909 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/PwPolicyMgrImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/PwPolicyMgrImpl.java
@@ -24,7 +24,7 @@ import org.apache.directory.fortress.core.PwPolicyMgr;
 import org.apache.directory.fortress.core.SecurityException;
 import org.apache.directory.fortress.core.model.PwPolicy;
 import org.apache.directory.fortress.core.model.User;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 import java.util.List;
 

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/ReviewMgrImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/ReviewMgrImpl.java b/src/main/java/org/apache/directory/fortress/core/rbac/ReviewMgrImpl.java
index b8e4d3c..2bd2a16 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/ReviewMgrImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/ReviewMgrImpl.java
@@ -29,7 +29,8 @@ import org.apache.directory.fortress.core.model.Role;
 import org.apache.directory.fortress.core.model.SDSet;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserRole;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
+import org.apache.directory.fortress.core.util.ObjUtil;
 
 import java.util.ArrayList;
 import java.util.HashSet;
@@ -499,7 +500,7 @@ public class ReviewMgrImpl extends Manageable implements ReviewMgr
         User ue = userP.read(user, true);
         List<UserRole> roles = ue.getRoles();
         Set<String> iRoles = null;
-        if (VUtil.isNotNullOrEmpty(roles))
+        if (ObjUtil.isNotNullOrEmpty(roles))
         {
             iRoles = RoleUtil.getInheritedRoles( roles, this.contextId );
         }
@@ -575,7 +576,7 @@ public class ReviewMgrImpl extends Manageable implements ReviewMgr
         checkAccess(CLS_NM, methodName);
         Permission pe = permP.read(perm);
         List<String> retVals;
-        if(pe != null && VUtil.isNotNullOrEmpty(pe.getRoles()))
+        if(pe != null && ObjUtil.isNotNullOrEmpty(pe.getRoles()))
         {
             retVals = new ArrayList<>(pe.getRoles());
         }
@@ -637,7 +638,7 @@ public class ReviewMgrImpl extends Manageable implements ReviewMgr
         checkAccess(CLS_NM, methodName);
         Permission pe = permP.read(perm);
         List<String> retVals;
-        if(pe != null && VUtil.isNotNullOrEmpty(pe.getUsers()))
+        if(pe != null && ObjUtil.isNotNullOrEmpty( pe.getUsers() ))
         {
             retVals = new ArrayList<>(pe.getUsers());
         }

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/RoleDAO.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/RoleDAO.java b/src/main/java/org/apache/directory/fortress/core/rbac/RoleDAO.java
index 5623900..dcc316c 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/RoleDAO.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/RoleDAO.java
@@ -47,7 +47,6 @@ import org.apache.directory.fortress.core.RemoveException;
 import org.apache.directory.fortress.core.UpdateException;
 import org.apache.directory.fortress.core.ldap.ApacheDsDataProvider;
 import org.apache.directory.fortress.core.model.Role;
-import org.apache.directory.fortress.core.util.attr.VUtil;
 import org.apache.directory.fortress.core.util.time.CUtil;
 
 

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/RoleP.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/RoleP.java b/src/main/java/org/apache/directory/fortress/core/rbac/RoleP.java
index 2a0c963..5a1a02a 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/RoleP.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/RoleP.java
@@ -31,7 +31,8 @@ import org.apache.directory.fortress.core.ValidationException;
 import org.apache.directory.fortress.core.model.Graphable;
 import org.apache.directory.fortress.core.model.Role;
 import org.apache.directory.fortress.core.model.UserRole;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
+import org.apache.directory.fortress.core.util.ObjUtil;
 
 
 /**
@@ -204,7 +205,7 @@ public final class RoleP
      */
     void addOccupant( List<UserRole> uRoles, String userDn, String contextId ) throws SecurityException
     {
-        if ( VUtil.isNotNullOrEmpty( uRoles ) )
+        if ( ObjUtil.isNotNullOrEmpty( uRoles ) )
         {
             for ( UserRole uRole : uRoles )
             {
@@ -274,7 +275,7 @@ public final class RoleP
         {
             VUtil.description( entity.getDescription() );
         }
-        if ( VUtil.isNotNullOrEmpty( entity.getTimeout() ) )
+        if ( ObjUtil.isNotNullOrEmpty( entity.getTimeout() ) )
         {
             VUtil.timeout( entity.getTimeout() );
         }

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/RoleUtil.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/RoleUtil.java b/src/main/java/org/apache/directory/fortress/core/rbac/RoleUtil.java
index d2d477b..4297092 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/RoleUtil.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/RoleUtil.java
@@ -32,13 +32,14 @@ import org.apache.directory.fortress.core.model.ParentUtil;
 import org.apache.directory.fortress.core.model.Relationship;
 import org.apache.directory.fortress.core.model.Role;
 import org.apache.directory.fortress.core.model.UserRole;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.jgrapht.graph.SimpleDirectedGraph;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.apache.directory.fortress.core.GlobalIds;
 import org.apache.directory.fortress.core.SecurityException;
 import org.apache.directory.fortress.core.ValidationException;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 import org.apache.directory.fortress.core.util.cache.Cache;
 import org.apache.directory.fortress.core.util.cache.CacheMgr;
 
@@ -201,14 +202,14 @@ public final class RoleUtil implements ParentUtil
     {
         // create Set with case insensitive comparator:
         Set<String> iRoles = new TreeSet<>( String.CASE_INSENSITIVE_ORDER );
-        if ( VUtil.isNotNullOrEmpty( uRoles ) )
+        if ( ObjUtil.isNotNullOrEmpty( uRoles ) )
         {
             for ( UserRole uRole : uRoles )
             {
                 String rleName = uRole.getName();
                 iRoles.add( rleName );
                 Set<String> parents = HierUtil.getAscendants( rleName, getGraph( contextId ) );
-                if ( VUtil.isNotNullOrEmpty( parents ) )
+                if ( ObjUtil.isNotNullOrEmpty( parents ) )
                 {
                     iRoles.addAll( parents );
                 }
@@ -228,13 +229,13 @@ public final class RoleUtil implements ParentUtil
     {
         // create Set with case insensitive comparator:
         Set<String> iRoles = new TreeSet<>( String.CASE_INSENSITIVE_ORDER );
-        if ( VUtil.isNotNullOrEmpty( roles ) )
+        if ( ObjUtil.isNotNullOrEmpty( roles ) )
         {
             for ( String role : roles )
             {
                 iRoles.add( role );
                 Set<String> parents = HierUtil.getAscendants( role, getGraph( contextId ) );
-                if ( VUtil.isNotNullOrEmpty( parents ) )
+                if ( ObjUtil.isNotNullOrEmpty( parents ) )
                 {
                     iRoles.addAll( parents );
                 }
@@ -254,13 +255,13 @@ public final class RoleUtil implements ParentUtil
     {
         // create Set with case insensitive comparator:
         Set<String> iRoles = new TreeSet<>( String.CASE_INSENSITIVE_ORDER );
-        if ( VUtil.isNotNullOrEmpty( roles ) )
+        if ( ObjUtil.isNotNullOrEmpty( roles ) )
         {
             for ( String role : roles )
             {
                 iRoles.add( role );
                 Set<String> children = HierUtil.getDescendants( role, getGraph( contextId ) );
-                if ( VUtil.isNotNullOrEmpty( children ) )
+                if ( ObjUtil.isNotNullOrEmpty( children ) )
                 {
                     iRoles.addAll( children );
                 }

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/SDUtil.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/SDUtil.java b/src/main/java/org/apache/directory/fortress/core/rbac/SDUtil.java
index 185515d..2cb65d2 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/SDUtil.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/SDUtil.java
@@ -32,7 +32,8 @@ import org.apache.directory.fortress.core.model.SDSet;
 import org.apache.directory.fortress.core.model.Session;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserRole;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.apache.directory.fortress.core.util.cache.Cache;
 import org.apache.directory.fortress.core.util.cache.CacheMgr;
 import org.apache.directory.fortress.core.util.cache.DsdCacheEntry;
@@ -117,7 +118,7 @@ final class SDUtil
         ReviewMgr rMgr = ReviewMgrFactory.createInstance(user.getContextId());
         Set<String> rls = rMgr.authorizedRoles(user);
         // Need to proceed?
-        if (!VUtil.isNotNullOrEmpty(rls))
+        if (!ObjUtil.isNotNullOrEmpty(rls))
         {
             return;
         }
@@ -161,7 +162,7 @@ final class SDUtil
     {
         // get all activated roles from user's session:
         List<UserRole> rls = session.getRoles();
-        if (!VUtil.isNotNullOrEmpty(rls))
+        if (!ObjUtil.isNotNullOrEmpty(rls))
         {
             // An empty list of roles was passed in the session variable.
             // No need to continue.
@@ -300,7 +301,7 @@ final class SDUtil
         contextId = getContextId(contextId);
         Set<SDSet> dsdRetSets = new HashSet<>();
         // Need to proceed?
-        if (!VUtil.isNotNullOrEmpty(authorizedRoleSet))
+        if (!ObjUtil.isNotNullOrEmpty(authorizedRoleSet))
         {
             return dsdRetSets;
         }
@@ -368,7 +369,7 @@ final class SDUtil
             Role role = new Role(roleName);
             role.setContextId(contextId);
             List<SDSet> dsdList = sp.search(role, SDSet.SDType.DYNAMIC);
-            if (VUtil.isNotNullOrEmpty(dsdList))
+            if (ObjUtil.isNotNullOrEmpty(dsdList))
             {
                 for (SDSet dsd : dsdList)
                 {
@@ -423,7 +424,7 @@ final class SDUtil
         role.setContextId(contextId);
         List<SDSet> dsdList = sp.search(role, SDSet.SDType.DYNAMIC);
         Set<SDSet> finalSet = new HashSet<>(dsdList);
-        if (VUtil.isNotNullOrEmpty(dsdList))
+        if ( ObjUtil.isNotNullOrEmpty( dsdList ))
         {
             for (SDSet dsd : dsdList)
             {

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/SdDAO.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/SdDAO.java b/src/main/java/org/apache/directory/fortress/core/rbac/SdDAO.java
index cc28c93..b24b7cb 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/SdDAO.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/SdDAO.java
@@ -39,6 +39,7 @@ import org.apache.directory.api.ldap.model.exception.LdapInvalidAttributeValueEx
 import org.apache.directory.api.ldap.model.exception.LdapNoSuchObjectException;
 import org.apache.directory.api.ldap.model.message.SearchScope;
 import org.apache.directory.fortress.core.model.SDSet;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.apache.directory.ldap.client.api.LdapConnection;
 import org.apache.directory.fortress.core.CreateException;
 import org.apache.directory.fortress.core.FinderException;
@@ -49,7 +50,7 @@ import org.apache.directory.fortress.core.RemoveException;
 import org.apache.directory.fortress.core.UpdateException;
 import org.apache.directory.fortress.core.ldap.ApacheDsDataProvider;
 import org.apache.directory.fortress.core.model.Role;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 
 /**
@@ -451,7 +452,7 @@ final class SdDAO extends ApacheDsDataProvider
             // Include any parents target role may have:
             Set<String> roles = RoleUtil.getAscendants( role.getName(), role.getContextId() );
 
-            if ( VUtil.isNotNullOrEmpty( roles ) )
+            if ( ObjUtil.isNotNullOrEmpty( roles ) )
             {
                 filterbuf.append( "|(" );
                 filterbuf.append( ROLES );
@@ -553,7 +554,7 @@ final class SdDAO extends ApacheDsDataProvider
 
         try
         {
-            if ( VUtil.isNotNullOrEmpty( roles ) )
+            if ( ObjUtil.isNotNullOrEmpty( roles ) )
             {
                 StringBuilder filterbuf = new StringBuilder();
                 filterbuf.append( GlobalIds.FILTER_PREFIX );

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/SdP.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/SdP.java b/src/main/java/org/apache/directory/fortress/core/rbac/SdP.java
index 79cba9a..60b4dcc 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/SdP.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/SdP.java
@@ -28,7 +28,7 @@ import org.apache.directory.fortress.core.GlobalIds;
 import org.apache.directory.fortress.core.SecurityException;
 import org.apache.directory.fortress.core.model.Role;
 import org.apache.directory.fortress.core.model.SDSet;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 
 /**

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/UserDAO.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/UserDAO.java b/src/main/java/org/apache/directory/fortress/core/rbac/UserDAO.java
index 63e99c4..87d7610 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/UserDAO.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/UserDAO.java
@@ -57,6 +57,7 @@ import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserAdminRole;
 import org.apache.directory.fortress.core.model.UserRole;
 import org.apache.directory.fortress.core.model.Warning;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.apache.directory.fortress.core.util.attr.AttrHelper;
 import org.apache.directory.ldap.client.api.LdapConnection;
 import org.slf4j.Logger;
@@ -72,7 +73,7 @@ import org.apache.directory.fortress.core.SecurityException;
 import org.apache.directory.fortress.core.UpdateException;
 import org.apache.directory.fortress.core.util.Config;
 import org.apache.directory.fortress.core.ldap.ApacheDsDataProvider;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 import org.apache.directory.fortress.core.util.time.CUtil;
 
 
@@ -432,7 +433,7 @@ final class UserDAO extends ApacheDsDataProvider
             myEntry.add( SchemaConstants.SN_AT, entity.getSn() );
 
             // guard against npe
-            myEntry.add( SchemaConstants.USER_PASSWORD_AT, VUtil.isNotNullOrEmpty( entity.getPassword() ) ? new
+            myEntry.add( SchemaConstants.USER_PASSWORD_AT, ObjUtil.isNotNullOrEmpty( entity.getPassword() ) ? new
                 String( entity.getPassword() ) : new String( new char[]
                     {} ) );
             myEntry.add( SchemaConstants.DISPLAY_NAME_AT, entity.getCn() );
@@ -482,7 +483,7 @@ final class UserDAO extends ApacheDsDataProvider
             loadAttrs( entity.getEmails(), myEntry, SchemaConstants.MAIL_AT );
 
             // The following attributes are optional:
-            if ( VUtil.isNotNullOrEmpty( entity.isSystem() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.isSystem() ) )
             {
                 myEntry.add( SYSTEM_USER, entity.isSystem().toString().toUpperCase() );
             }
@@ -513,7 +514,7 @@ final class UserDAO extends ApacheDsDataProvider
             myEntry.add( GlobalIds.CONSTRAINT, CUtil.setConstraint( entity ) );
             loadAddress( entity.getAddress(), myEntry );
 
-            if ( VUtil.isNotNullOrEmpty( entity.getJpegPhoto() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getJpegPhoto() ) )
             {
                 myEntry.add( JPEGPHOTO, entity.getJpegPhoto() );
             }
@@ -568,7 +569,7 @@ final class UserDAO extends ApacheDsDataProvider
                     entity.getOu() ) );
             }
 
-            if ( VUtil.isNotNullOrEmpty( entity.getPassword() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getPassword() ) )
             {
                 mods.add( new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE, SchemaConstants
                     .USER_PASSWORD_AT, new String( entity.getPassword() ) ) );
@@ -600,7 +601,7 @@ final class UserDAO extends ApacheDsDataProvider
                     szDn ) );
             }
 
-            if ( VUtil.isNotNullOrEmpty( entity.isSystem() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.isSystem() ) )
             {
                 mods.add( new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE, SYSTEM_USER, entity
                     .isSystem().toString().toUpperCase() ) );
@@ -619,7 +620,7 @@ final class UserDAO extends ApacheDsDataProvider
                 }
             }
 
-            if ( VUtil.isNotNullOrEmpty( entity.getProperties() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getProperties() ) )
             {
                 loadProperties( entity.getProperties(), mods, GlobalIds.PROPS, true );
             }
@@ -631,7 +632,7 @@ final class UserDAO extends ApacheDsDataProvider
             loadAttrs( entity.getMobiles(), mods, MOBILE );
             loadAttrs( entity.getEmails(), mods, SchemaConstants.MAIL_AT );
 
-            if ( VUtil.isNotNullOrEmpty( entity.getJpegPhoto() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getJpegPhoto() ) )
             {
                 mods.add( new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE, JPEGPHOTO, entity
                     .getJpegPhoto() ) );
@@ -675,7 +676,7 @@ final class UserDAO extends ApacheDsDataProvider
         {
             List<Modification> mods = new ArrayList<Modification>();
 
-            if ( VUtil.isNotNullOrEmpty( entity.getProperties() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getProperties() ) )
             {
                 loadProperties( entity.getProperties(), mods, GlobalIds.PROPS, replace );
             }
@@ -1273,7 +1274,7 @@ final class UserDAO extends ApacheDsDataProvider
 
             Set<String> roles = RoleUtil.getDescendants( role.getName(), role.getContextId() );
 
-            if ( VUtil.isNotNullOrEmpty( roles ) )
+            if ( ObjUtil.isNotNullOrEmpty( roles ) )
             {
                 filterbuf.append( "|(" );
                 filterbuf.append( GlobalIds.USER_ROLE_ASSIGN );
@@ -1404,7 +1405,7 @@ final class UserDAO extends ApacheDsDataProvider
             filterbuf.append( USERS_AUX_OBJECT_CLASS_NAME );
             filterbuf.append( ")(|" );
 
-            if ( VUtil.isNotNullOrEmpty( roles ) )
+            if ( ObjUtil.isNotNullOrEmpty( roles ) )
             {
                 for ( String roleVal : roles )
                 {
@@ -2281,7 +2282,7 @@ final class UserDAO extends ApacheDsDataProvider
     {
         if ( address != null )
         {
-            if ( VUtil.isNotNullOrEmpty( address.getAddresses() ) )
+            if ( ObjUtil.isNotNullOrEmpty( address.getAddresses() ) )
             {
                 for ( String val : address.getAddresses() )
                 {
@@ -2342,7 +2343,7 @@ final class UserDAO extends ApacheDsDataProvider
     {
         if ( address != null )
         {
-            if ( VUtil.isNotNullOrEmpty( address.getAddresses() ) )
+            if ( ObjUtil.isNotNullOrEmpty( address.getAddresses() ) )
             {
                 mods.add( new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE, SchemaConstants
                     .POSTAL_ADDRESS_AT ) );

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/UserP.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/UserP.java b/src/main/java/org/apache/directory/fortress/core/rbac/UserP.java
index 7b234d8..00f136f 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/UserP.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/UserP.java
@@ -33,6 +33,7 @@ import org.apache.directory.fortress.core.model.Session;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserAdminRole;
 import org.apache.directory.fortress.core.model.UserRole;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.apache.directory.fortress.core.util.attr.AttrHelper;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -43,7 +44,7 @@ import org.apache.directory.fortress.core.model.ObjectFactory;
 import org.apache.directory.fortress.core.PasswordException;
 import org.apache.directory.fortress.core.SecurityException;
 import org.apache.directory.fortress.core.ValidationException;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 import org.apache.directory.fortress.core.util.time.CUtil;
 
 
@@ -321,7 +322,7 @@ public final class UserP
         // Ensure this user isn't listed in Fortress config as a system user that can't be removed via API.
         // Is there a match between this userId and a Fortress system user?
         User checkUser = read( user, true );
-        if ( VUtil.isNotNullOrEmpty( checkUser.isSystem() ) && checkUser.isSystem() )
+        if ( ObjUtil.isNotNullOrEmpty( checkUser.isSystem() ) && checkUser.isSystem() )
         {
             String warning = "softDelete userId [" + user.getUserId()
                 + "] can't be removed due to policy violation, rc=" + GlobalErrIds.USER_PLCY_VIOLATION;
@@ -346,7 +347,7 @@ public final class UserP
         // Ensure this user isn't listed in Fortress config as a system user that can't be removed via API.
         // Is there a match between this userId and a Fortress system user?
         User checkUser = read( user, true );
-        if ( VUtil.isNotNullOrEmpty( checkUser.isSystem() ) && checkUser.isSystem() )
+        if ( ObjUtil.isNotNullOrEmpty( checkUser.isSystem() ) && checkUser.isSystem() )
         {
             String warning = "delete userId [" + user.getUserId()
                 + "] can't be removed due to policy violation, rc=" + GlobalErrIds.USER_PLCY_VIOLATION;
@@ -461,7 +462,7 @@ public final class UserP
             session = createSession( user );
         }
         // Did the caller pass in a set of roles for selective activation?
-        if ( VUtil.isNotNullOrEmpty( user.getRoles() ) )
+        if ( ObjUtil.isNotNullOrEmpty( user.getRoles() ) )
         {
             // Process selective activation of user's RBAC roles into session:
             List<UserRole> rlsActual = session.getRoles();
@@ -758,7 +759,7 @@ public final class UserP
                 VUtil.safeText( entity.getSn(), GlobalIds.SN_LEN );
             }
             // password is not required on user object but user cannot execute AccessMgr or DelAccessMgr methods w/out pw.
-            if ( VUtil.isNotNullOrEmpty( entity.getPassword() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getPassword() ) )
             {
                 VUtil.password( entity.getPassword() );
             }
@@ -795,7 +796,7 @@ public final class UserP
             {
                 VUtil.safeText( entity.getSn(), GlobalIds.SN_LEN );
             }
-            if ( VUtil.isNotNullOrEmpty( entity.getPassword() ) )
+            if ( ObjUtil.isNotNullOrEmpty( entity.getPassword() ) )
             {
                 VUtil.password( entity.getPassword() );
             }
@@ -836,7 +837,7 @@ public final class UserP
         CUtil.validate( entity );
 
         // 3 Validate or copy constraints on RBAC roles:
-        if ( VUtil.isNotNullOrEmpty( entity.getRoles() ) )
+        if ( ObjUtil.isNotNullOrEmpty( entity.getRoles() ) )
         {
             RoleP rp = new RoleP();
             List<UserRole> roles = entity.getRoles();
@@ -850,7 +851,7 @@ public final class UserP
         }
 
         // 4 Validate and copy constraints on Administrative roles:
-        if ( VUtil.isNotNullOrEmpty( entity.getAdminRoles() ) )
+        if ( ObjUtil.isNotNullOrEmpty( entity.getAdminRoles() ) )
         {
             List<UserAdminRole> uRoles = entity.getAdminRoles();
             for ( UserAdminRole uare : uRoles )

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rbac/UsoUtil.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rbac/UsoUtil.java b/src/main/java/org/apache/directory/fortress/core/rbac/UsoUtil.java
index f29e94a..2d39ff1 100755
--- a/src/main/java/org/apache/directory/fortress/core/rbac/UsoUtil.java
+++ b/src/main/java/org/apache/directory/fortress/core/rbac/UsoUtil.java
@@ -30,13 +30,14 @@ import org.apache.directory.fortress.core.model.Graphable;
 import org.apache.directory.fortress.core.model.Hier;
 import org.apache.directory.fortress.core.model.OrgUnit;
 import org.apache.directory.fortress.core.model.Relationship;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.jgrapht.graph.SimpleDirectedGraph;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.apache.directory.fortress.core.GlobalIds;
 import org.apache.directory.fortress.core.SecurityException;
 import org.apache.directory.fortress.core.ValidationException;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 import org.apache.directory.fortress.core.util.cache.Cache;
 import org.apache.directory.fortress.core.util.cache.CacheMgr;
 
@@ -158,7 +159,7 @@ public final class UsoUtil
         // create Set with case insensitive comparator:
         Set<String> iOUs = new TreeSet<>( String.CASE_INSENSITIVE_ORDER );
         
-        if ( VUtil.isNotNullOrEmpty( ous ) )
+        if ( ObjUtil.isNotNullOrEmpty( ous ) )
         {
             for ( OrgUnit ou : ous )
             {
@@ -166,7 +167,7 @@ public final class UsoUtil
                 iOUs.add( name );
                 Set<String> parents = HierUtil.getAscendants( name, getGraph( contextId ) );
                 
-                if ( VUtil.isNotNullOrEmpty( parents ) )
+                if ( ObjUtil.isNotNullOrEmpty( parents ) )
                 {
                     iOUs.addAll( parents );
                 }

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rest/AccessMgrRestImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rest/AccessMgrRestImpl.java b/src/main/java/org/apache/directory/fortress/core/rest/AccessMgrRestImpl.java
index 01edf4a..d8128fa 100644
--- a/src/main/java/org/apache/directory/fortress/core/rest/AccessMgrRestImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rest/AccessMgrRestImpl.java
@@ -30,7 +30,7 @@ import org.apache.directory.fortress.core.model.Permission;
 import org.apache.directory.fortress.core.model.Session;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserRole;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 import java.util.List;
 import java.util.Set;

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rest/AdminMgrRestImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rest/AdminMgrRestImpl.java b/src/main/java/org/apache/directory/fortress/core/rest/AdminMgrRestImpl.java
index e599566..7323fdb 100644
--- a/src/main/java/org/apache/directory/fortress/core/rest/AdminMgrRestImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rest/AdminMgrRestImpl.java
@@ -34,7 +34,7 @@ import org.apache.directory.fortress.core.model.SDSet;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserRole;
 import org.apache.directory.fortress.core.rbac.Manageable;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 
 /**

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rest/AuditMgrRestImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rest/AuditMgrRestImpl.java b/src/main/java/org/apache/directory/fortress/core/rest/AuditMgrRestImpl.java
index f05a037..3610592 100644
--- a/src/main/java/org/apache/directory/fortress/core/rest/AuditMgrRestImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rest/AuditMgrRestImpl.java
@@ -29,7 +29,7 @@ import org.apache.directory.fortress.core.model.FortResponse;
 import org.apache.directory.fortress.core.rbac.Manageable;
 import org.apache.directory.fortress.core.model.Mod;
 import org.apache.directory.fortress.core.model.UserAudit;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 import java.util.ArrayList;
 import java.util.List;

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rest/ConfigMgrRestImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rest/ConfigMgrRestImpl.java b/src/main/java/org/apache/directory/fortress/core/rest/ConfigMgrRestImpl.java
index 4d07dbc..c14ac17 100644
--- a/src/main/java/org/apache/directory/fortress/core/rest/ConfigMgrRestImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rest/ConfigMgrRestImpl.java
@@ -25,7 +25,7 @@ import org.apache.directory.fortress.core.ConfigMgr;
 import org.apache.directory.fortress.core.model.FortRequest;
 import org.apache.directory.fortress.core.model.FortResponse;
 import org.apache.directory.fortress.core.model.Props;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 import java.util.Properties;
 

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rest/DelAccessMgrRestImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rest/DelAccessMgrRestImpl.java b/src/main/java/org/apache/directory/fortress/core/rest/DelAccessMgrRestImpl.java
index b5562ff..d1582b7 100644
--- a/src/main/java/org/apache/directory/fortress/core/rest/DelAccessMgrRestImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rest/DelAccessMgrRestImpl.java
@@ -30,7 +30,7 @@ import org.apache.directory.fortress.core.model.Session;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserRole;
 import org.apache.directory.fortress.core.model.Role;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 import org.apache.directory.fortress.core.SecurityException;
 
 import java.util.List;

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rest/DelAdminMgrRestImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rest/DelAdminMgrRestImpl.java b/src/main/java/org/apache/directory/fortress/core/rest/DelAdminMgrRestImpl.java
index a75b07d..5ac9c14 100644
--- a/src/main/java/org/apache/directory/fortress/core/rest/DelAdminMgrRestImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rest/DelAdminMgrRestImpl.java
@@ -34,7 +34,7 @@ import org.apache.directory.fortress.core.model.Permission;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserAdminRole;
 import org.apache.directory.fortress.core.GlobalErrIds;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 
 /**

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rest/DelReviewMgrRestImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rest/DelReviewMgrRestImpl.java b/src/main/java/org/apache/directory/fortress/core/rest/DelReviewMgrRestImpl.java
index 26757d5..30ed58e 100644
--- a/src/main/java/org/apache/directory/fortress/core/rest/DelReviewMgrRestImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rest/DelReviewMgrRestImpl.java
@@ -29,7 +29,7 @@ import org.apache.directory.fortress.core.rbac.Manageable;
 import org.apache.directory.fortress.core.model.OrgUnit;
 import org.apache.directory.fortress.core.model.UserAdminRole;
 import org.apache.directory.fortress.core.model.User;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 import java.util.ArrayList;
 import java.util.List;

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rest/PwPolicyMgrRestImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rest/PwPolicyMgrRestImpl.java b/src/main/java/org/apache/directory/fortress/core/rest/PwPolicyMgrRestImpl.java
index 45b0509..768c02d 100644
--- a/src/main/java/org/apache/directory/fortress/core/rest/PwPolicyMgrRestImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rest/PwPolicyMgrRestImpl.java
@@ -27,7 +27,7 @@ import org.apache.directory.fortress.core.model.FortRequest;
 import org.apache.directory.fortress.core.model.FortResponse;
 import org.apache.directory.fortress.core.rbac.Manageable;
 import org.apache.directory.fortress.core.model.PwPolicy;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 import java.util.List;
 

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/rest/ReviewMgrRestImpl.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/rest/ReviewMgrRestImpl.java b/src/main/java/org/apache/directory/fortress/core/rest/ReviewMgrRestImpl.java
index e45597b..2df59e0 100755
--- a/src/main/java/org/apache/directory/fortress/core/rest/ReviewMgrRestImpl.java
+++ b/src/main/java/org/apache/directory/fortress/core/rest/ReviewMgrRestImpl.java
@@ -32,7 +32,7 @@ import org.apache.directory.fortress.core.model.Role;
 import org.apache.directory.fortress.core.model.SDSet;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserRole;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 import java.util.ArrayList;
 import java.util.List;

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/util/ObjUtil.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/util/ObjUtil.java b/src/main/java/org/apache/directory/fortress/core/util/ObjUtil.java
new file mode 100644
index 0000000..1e39e32
--- /dev/null
+++ b/src/main/java/org/apache/directory/fortress/core/util/ObjUtil.java
@@ -0,0 +1,126 @@
+/*
+ *   Licensed to the Apache Software Foundation (ASF) under one
+ *   or more contributor license agreements.  See the NOTICE file
+ *   distributed with this work for additional information
+ *   regarding copyright ownership.  The ASF licenses this file
+ *   to you under the Apache License, Version 2.0 (the
+ *   "License"); you may not use this file except in compliance
+ *   with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *   Unless required by applicable law or agreed to in writing,
+ *   software distributed under the License is distributed on an
+ *   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *   KIND, either express or implied.  See the License for the
+ *   specific language governing permissions and limitations
+ *   under the License.
+ *
+ */
+
+package org.apache.directory.fortress.core.util;
+
+import java.util.Collection;
+import java.util.Properties;
+
+/**
+ * Contains utilities for null checks of various objects.
+ *
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ */
+public final class ObjUtil
+{
+    // cannot construct
+    private ObjUtil()
+    {
+
+    }
+
+    /**
+     * Method will return true if string array reference is not null or empty.
+     *
+     * @param value contains the reference to string array.
+     * @return boolean if validation succeeds.
+     */
+    public static boolean isNotNullOrEmpty( String[] value )
+    {
+        return ( value != null ) && ( value.length > 0 );
+    }
+
+
+    /**
+     * Method will return true if string reference is not null or empty.
+     *
+     * @param value contains the reference to string.
+     * @return boolean if validation succeeds.
+     */
+    public static boolean isNotNullOrEmpty( char[] value )
+    {
+        return ( value != null ) && ( value.length > 0 );
+    }
+
+
+    /**
+     * Method will return true if list is not null or empty.
+     *
+     * @param list contains the reference to list.
+     * @return boolean if validation succeeds.
+     */
+    public static boolean isNotNullOrEmpty( Collection<?> list )
+    {
+        return ( list != null ) && ( list.size() > 0 );
+    }
+
+
+    /**
+     * Method will return true if props is not null or empty.
+     *
+     * @param props contains the reference to props.
+     * @return boolean if validation succeeds.
+     */
+    public static boolean isNotNullOrEmpty( Properties props )
+    {
+        return ( props != null ) && ( props.size() > 0 );
+    }
+
+
+    /**
+     * Method will return true if input is not null or empty.
+     *
+     * @param iVal contains the reference to Integer variable.
+     * @return boolean if validation succeeds.
+     */
+    public static boolean isNotNullOrEmpty( Integer iVal )
+    {
+        return ( iVal != null );
+    }
+
+
+    /**
+     * Method will return true if input is not null or empty.
+     *
+     * @param bVal contains the reference to Boolean variable.
+     * @return boolean if validation succeeds.
+     */
+    public static boolean isNotNullOrEmpty( Boolean bVal )
+    {
+        return ( bVal != null );
+    }
+
+
+    /**
+     * Method will return true if byte array reference is not null or empty.
+     *
+     * @param value contains the reference to byte array.
+     * @return boolean if validation succeeds.
+     */
+    public static boolean isNotNullOrEmpty( byte[] value )
+    {
+        boolean result = false;
+        if ( value != null && value.length > 0 )
+        {
+            result = true;
+        }
+        return result;
+    }
+}

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/util/attr/AttrHelper.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/util/attr/AttrHelper.java b/src/main/java/org/apache/directory/fortress/core/util/attr/AttrHelper.java
index e49f978..159ca61 100755
--- a/src/main/java/org/apache/directory/fortress/core/util/attr/AttrHelper.java
+++ b/src/main/java/org/apache/directory/fortress/core/util/attr/AttrHelper.java
@@ -27,6 +27,8 @@ import org.apache.directory.fortress.core.GlobalIds;
 import org.apache.directory.fortress.core.model.Administrator;
 import org.apache.directory.fortress.core.model.AuthZ;
 import org.apache.directory.fortress.core.model.Permission;
+import org.apache.directory.fortress.core.model.VUtil;
+import org.apache.directory.fortress.core.util.ObjUtil;
 
 import java.text.ParseException;
 import java.util.Date;
@@ -209,7 +211,7 @@ public final class AttrHelper
         // Here the sample reqDN=ftOpNm=TOP2_2+ftObjId=002,ftObjNm=TOB2_1,ou=Permissions,ou=RBAC,dc=example,dc=com
         // Will be mapped to objName=TOB2_1, opName=TOP2_2, objId=002, in the returned permission object.
         Dn dn = new Dn( authZ.getReqDN() );
-        if(dn != null && dn.getRdns() != null && VUtil.isNotNullOrEmpty( dn.getRdns() ) )
+        if(dn != null && dn.getRdns() != null && ObjUtil.isNotNullOrEmpty( dn.getRdns() ) )
         {
             for( Rdn rdn : dn.getRdns() )
             {

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/util/attr/RegExUtil.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/util/attr/RegExUtil.java b/src/main/java/org/apache/directory/fortress/core/util/attr/RegExUtil.java
deleted file mode 100755
index 693627f..0000000
--- a/src/main/java/org/apache/directory/fortress/core/util/attr/RegExUtil.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- *   Licensed to the Apache Software Foundation (ASF) under one
- *   or more contributor license agreements.  See the NOTICE file
- *   distributed with this work for additional information
- *   regarding copyright ownership.  The ASF licenses this file
- *   to you under the Apache License, Version 2.0 (the
- *   "License"); you may not use this file except in compliance
- *   with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *   Unless required by applicable law or agreed to in writing,
- *   software distributed under the License is distributed on an
- *   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *   KIND, either express or implied.  See the License for the
- *   specific language governing permissions and limitations
- *   under the License.
- *
- */
-package org.apache.directory.fortress.core.util.attr;
-
-
-import org.apache.directory.api.util.Strings;
-import org.apache.directory.fortress.core.GlobalErrIds;
-import org.apache.directory.fortress.core.GlobalIds;
-import org.apache.directory.fortress.core.ValidationException;
-import org.apache.directory.fortress.core.util.Config;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-
-/**
- *  Regular expression utilities to perform data validations on Fortress attributes.  These utils use the standard
- * java regular expression library.
- *
- * @author     Shawn McKinney
- */
-final class RegExUtil
-{
-    private static final String CLS_NM = RegExUtil.class.getName();
-    private static final Logger LOG = LoggerFactory.getLogger( CLS_NM );
-    private static final String SAFE_TEXT_PATTERN_STRING = Config.getProperty( GlobalIds.REG_EX_SAFE_TEXT );
-    private static Pattern safeTextPattern;
-    
-    static 
-    {
-        if ( ( SAFE_TEXT_PATTERN_STRING != null ) && ( SAFE_TEXT_PATTERN_STRING.length() != 0 ) )
-        {
-            safeTextPattern = Pattern.compile( SAFE_TEXT_PATTERN_STRING );
-        }
-    }
-
-    /**
-     * Private constructor
-     *
-     */
-    private RegExUtil()
-    {
-    }
-
-    /**
-     *  Perform safe text validation on character string.
-     *
-     * @param  value Contains the string to check.
-     * @exception org.apache.directory.fortress.core.ValidationException  In the event the data validation fails.
-     */
-    public static void safeText( String value ) throws ValidationException
-    {
-        if ( Strings.isEmpty( SAFE_TEXT_PATTERN_STRING ) )
-        {
-            LOG.debug( "safeText can't find safeText regular expression pattern.  Check your Fortress cfg" );
-        }
-        else
-        {
-            Matcher safeTextMatcher = safeTextPattern.matcher( value );
-            
-            if ( !safeTextMatcher.find() )
-            {
-                String error = "safeText has detected invalid value [" + value + "]";
-                throw new ValidationException( GlobalErrIds.CONST_INVLD_TEXT, error );
-            }
-        }
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/util/attr/VUtil.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/util/attr/VUtil.java b/src/main/java/org/apache/directory/fortress/core/util/attr/VUtil.java
deleted file mode 100755
index 1b65167..0000000
--- a/src/main/java/org/apache/directory/fortress/core/util/attr/VUtil.java
+++ /dev/null
@@ -1,588 +0,0 @@
-/*
- *   Licensed to the Apache Software Foundation (ASF) under one
- *   or more contributor license agreements.  See the NOTICE file
- *   distributed with this work for additional information
- *   regarding copyright ownership.  The ASF licenses this file
- *   to you under the Apache License, Version 2.0 (the
- *   "License"); you may not use this file except in compliance
- *   with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *   Unless required by applicable law or agreed to in writing,
- *   software distributed under the License is distributed on an
- *   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *   KIND, either express or implied.  See the License for the
- *   specific language governing permissions and limitations
- *   under the License.
- *
- */
-package org.apache.directory.fortress.core.util.attr;
-
-
-import java.text.ParseException;
-import java.text.SimpleDateFormat;
-import java.util.Collection;
-import java.util.Enumeration;
-import java.util.Properties;
-
-import org.apache.commons.lang.StringUtils;
-import org.slf4j.LoggerFactory;
-import org.apache.directory.fortress.core.GlobalErrIds;
-import org.apache.directory.fortress.core.GlobalIds;
-import org.apache.directory.fortress.core.ValidationException;
-import org.apache.directory.fortress.core.util.Config;
-
-
-/**
- * This class contains simple data validation utilities.  The data validations include null, length
- * and simple reasonability checking.  All utilities will throw {@link ValidationException} for failures.
- */
-public final class VUtil
-{
-    private static final String CLS_NM = VUtil.class.getName();
-    private static final org.slf4j.Logger LOG = LoggerFactory.getLogger( CLS_NM );
-    private static int maximumFieldLen = 130;
-    private static final String VALIDATE_LENGTH = "field.length";
-
-    static
-    {
-        String lengthProp = Config.getProperty( VALIDATE_LENGTH );
-        try
-        {
-            if ( lengthProp != null )
-            {
-                Integer len = Integer.valueOf( lengthProp );
-                maximumFieldLen = len;
-            }
-        }
-        catch ( java.lang.NumberFormatException nfe )
-        {
-            //ignore
-        }
-    }
-
-    private static final int MAXIMUM_FIELD_LEN = maximumFieldLen;
-    private static final int maxFieldLength = MAXIMUM_FIELD_LEN;
-    private static final int TIME_LEN = 4;
-    private static final int DATE_LEN = 8;
-    private static final int DAYMASK_LEN = 7;
-    private static final String TIME_FORMAT = "HHmm";
-    private static final String DATE_FORMAT = "yyyyMMdd";
-    private static final char SUNDAY = '1';
-    private static final char SATURDAY = '7';
-    private static final SimpleDateFormat TIME_FORMATER = new SimpleDateFormat( TIME_FORMAT );
-    private static final SimpleDateFormat DATE_FORMATER = new SimpleDateFormat( DATE_FORMAT );
-
-    static
-    {
-        String lengthProp = Config.getProperty( VALIDATE_LENGTH );
-
-        if ( lengthProp != null )
-        {
-            maximumFieldLen = Integer.parseInt( lengthProp );
-        }
-
-        TIME_FORMATER.setLenient( false );
-        DATE_FORMATER.setLenient( false );
-    }
-
-    /**
-     * Private constructor
-     *
-     */
-    private VUtil()
-    {
-    }
-
-    /**
-     * Simple length check on orgunit that uses {@link org.apache.directory.fortress.core.GlobalIds#OU_LEN}.
-     *
-     * @param orgUnitId contains the ou name.
-     * @throws ValidationException in the event of failure, {@link org.apache.directory.fortress.core.GlobalErrIds#ORG_LEN_INVLD}.
-     */
-    public static void orgUnit( String orgUnitId ) throws ValidationException
-    {
-        if ( !StringUtils.isNotEmpty( orgUnitId ) )
-        {
-            String error = "orgUnit is null";
-            throw new ValidationException( GlobalErrIds.ORG_NULL, error );
-        }
-        int length = orgUnitId.length();
-
-        if ( length > maxFieldLength )
-        {
-            String error = "orgUnit value [" + orgUnitId + "] invalid length [" + length + "]";
-            throw new ValidationException( GlobalErrIds.ORG_LEN_INVLD, error );
-        }
-    }
-
-
-    /**
-     * Simple length check on User password that uses {@link org.apache.directory.fortress.core.GlobalIds#PASSWORD_LEN}.
-     * @param password contains the User's password.
-     * @throws ValidationException in the event of failure, {@link org.apache.directory.fortress.core.GlobalErrIds#USER_PW_INVLD_LEN}.
-     */
-    public static void password( char[] password ) throws ValidationException
-    {
-        int length = password.length;
-
-        if ( length > GlobalIds.PASSWORD_LEN )
-        {
-            String error = "password invalid length [" + length + "]";
-            throw new ValidationException( GlobalErrIds.USER_PW_INVLD_LEN, error );
-        }
-    }
-
-
-    /**
-     * Simple length check and safe text validation on description field that uses {@link org.apache.directory.fortress.core.GlobalIds#DESC_LEN}.
-     *
-     * @param value contains the entity description.
-     * @throws org.apache.directory.fortress.core.ValidationException
-     *          in the event of failure, {@link org.apache.directory.fortress.core.GlobalErrIds#CONST_DESC_LEN_INVLD}.
-     */
-    public static void description( String value ) throws ValidationException
-    {
-        int length = value.length();
-
-        if ( length > GlobalIds.DESC_LEN )
-        {
-            String error = "description value [" + value + "] invalid length [" + length + "]";
-            throw new ValidationException( GlobalErrIds.CONST_DESC_LEN_INVLD, error );
-        }
-
-        RegExUtil.safeText( value );
-    }
-
-
-    /**
-     * Perform a simple length and safe text validation.
-     *
-     * @param value contains the attribute to check.
-     * @param validLen contains the length to use.
-     * @throws ValidationException in the event of length {@link org.apache.directory.fortress.core.GlobalErrIds#CONST_INVLD_FIELD_LEN} or regex failure.
-     */
-    public static void safeText( String value, int validLen ) throws ValidationException
-    {
-        if ( !StringUtils.isNotEmpty( value ) )
-        {
-            String error = "safeText null value";
-            throw new ValidationException( GlobalErrIds.CONST_NULL_TEXT, error );
-        }
-
-        int length = value.length();
-
-        if ( length > validLen )
-        {
-            String error = "safeText value [" + value + "] invalid length [" + length + "]";
-            throw new ValidationException( GlobalErrIds.CONST_INVLD_FIELD_LEN, error );
-        }
-
-        RegExUtil.safeText( value );
-    }
-
-
-    /**
-     * Simple null, {@link org.apache.directory.fortress.core.GlobalErrIds#USER_ID_NULL}, and length checks, {@link org.apache.directory.fortress.core.GlobalErrIds#CONST_INVLD_FIELD_LEN}, on userId.
-     *
-     * @param userId contains the userId, maps to {@link org.apache.directory.fortress.core.model.User#userId}.
-     * @throws ValidationException in the event of failure, {@link GlobalErrIds#CONST_INVLD_FIELD_LEN}.
-     */
-    public static void userId( String userId ) throws ValidationException
-    {
-        if ( !StringUtils.isNotEmpty( userId ) )
-        {
-            String error = "userId validation failed, null or empty value";
-            throw new ValidationException( GlobalErrIds.USER_ID_NULL, error );
-        }
-
-        int length = userId.length();
-
-        if ( length > GlobalIds.USERID_LEN )
-        {
-            String error = "safeText value [" + userId + "] invalid length [" + length + "]";
-            throw new ValidationException( GlobalErrIds.CONST_INVLD_FIELD_LEN, error );
-        }
-    }
-
-
-    /**
-     * Perform simple length and safe text validations on collection of name-value pairs.
-     *
-     * @param props contains name-value pairs in {@code name:value} format.
-     * @throws ValidationException in the event of failure.
-     */
-    public static void properties( Properties props ) throws ValidationException
-    {
-        if ( isNotNullOrEmpty( props ) )
-        {
-            for ( Enumeration<?> e = props.propertyNames(); e.hasMoreElements(); )
-            {
-                String key = ( String ) e.nextElement();
-                String val = props.getProperty( key );
-                safeText( key, GlobalIds.PROP_LEN );
-                safeText( val, GlobalIds.PROP_LEN );
-            }
-        }
-    }
-
-
-    /**
-     * Perform simple reasonability check on contraint timeout value.
-     *
-     * @param timeout must be greater than 0 and less than max value for {@link Integer#MAX_VALUE}
-     * @throws org.apache.directory.fortress.core.ValidationException
-     *          in the event value falls out of range.
-     */
-    public static void timeout( Integer timeout ) throws ValidationException
-    {
-        if ( ( timeout < 0 ) || ( timeout >= Integer.MAX_VALUE ) )
-        {
-            String error = "timeout - invalid timeout value [" + timeout + "]";
-            throw new ValidationException( GlobalErrIds.CONST_TIMEOUT_INVLD, error );
-        }
-    }
-
-
-    /**
-     * Perform simple reasonability check on contraint beginTime value.
-     *
-     * @param beginTime if set, must be equal to {@link #TIME_LEN}.
-     * @throws org.apache.directory.fortress.core.ValidationException
-     *          in the event value falls out of range.
-     */
-    public static void beginTime( String beginTime ) throws ValidationException
-    {
-        if ( ( beginTime != null ) && ( beginTime.length() == TIME_LEN ) )
-        {
-            if ( checkTime( beginTime ) )
-            {
-                String error = "beginTime - invalid beginTime value [" + beginTime + "]";
-                throw new ValidationException( GlobalErrIds.CONST_BEGINTIME_INVLD, error );
-            }
-        }
-        else
-        {
-            String error = "beginTime - null or invalid length (must be 4) for beginTime value";
-            throw new ValidationException( GlobalErrIds.CONST_BEGINTIME_LEN_ERR, error );
-        }
-    }
-
-
-    /**
-     * Perform simple reasonability check on contraint endTime value.
-     * @param endTime if set, must be equal to {@link #TIME_LEN}.
-     * @throws ValidationException in the event value falls out of range.
-     */
-    public static void endTime( String endTime ) throws ValidationException
-    {
-        if ( ( endTime != null ) && ( endTime.length() == TIME_LEN ) )
-        {
-            if ( checkTime( endTime ) )
-            {
-                String error = "endTime - invalid endTime value [" + endTime + "]";
-                throw new ValidationException( GlobalErrIds.CONST_ENDTIME_INVLD, error );
-            }
-        }
-        else
-        {
-            String error = "endTime - null or invalid length (must be 4) for endTime value";
-            throw new ValidationException( GlobalErrIds.CONST_ENDTIME_LEN_ERR, error );
-        }
-    }
-
-
-    /**
-     * Perform simple reasonability check on contraint beginDate value.
-     * @param beginDate if set, must be equal to {@link #DATE_LEN}.
-     * @throws ValidationException in the event value falls out of range.
-     */
-    public static void beginDate( String beginDate )
-        throws ValidationException
-    {
-        if ( StringUtils.isNotEmpty( beginDate ) )
-        {
-            if ( ( beginDate.compareToIgnoreCase( GlobalIds.NONE ) != 0 ) &&
-                ( ( beginDate.length() != DATE_LEN ) || checkDate( beginDate ) ) )
-            {
-                String error = "beginDate - invalid beginDate value [" + beginDate + "]";
-                throw new ValidationException( GlobalErrIds.CONST_BEGINDATE_INVLD, error );
-            }
-        }
-        else
-        {
-            String error = "beginDate - null or empty beginDate value";
-            throw new ValidationException( GlobalErrIds.CONST_BEGINDATE_NULL, error );
-        }
-    }
-
-
-    /**
-     * Perform simple reasonability check on contraint endDate value.
-     * @param endDate if set, must be equal to {@link #DATE_LEN}.
-     * @throws ValidationException in the event value falls out of range.
-     */
-    public static void endDate( String endDate ) throws ValidationException
-    {
-        if ( StringUtils.isNotEmpty( endDate ) )
-        {
-            if ( endDate.compareToIgnoreCase( GlobalIds.NONE ) != 0 )
-            {
-                if ( endDate.length() != DATE_LEN || checkDate( endDate ) )
-                {
-                    String error = "endDate - invalid endDate value [" + endDate + "]";
-                    throw new ValidationException( GlobalErrIds.CONST_ENDDATE_INVLD, error );
-                }
-            }
-        }
-        else
-        {
-            String error = "endDate - null or empty endDate value";
-            throw new ValidationException( GlobalErrIds.CONST_ENDDATE_NULL, error );
-        }
-    }
-
-
-    /**
-     * Perform simple reasonability check on contraint dayMask value.
-     * @param dayMask if set, will be validated.
-     * @throws ValidationException in the event value falls out of range.
-     */
-    public static void dayMask( String dayMask ) throws ValidationException
-    {
-        if ( StringUtils.isNotEmpty( dayMask ) )
-        {
-            if ( dayMask.compareToIgnoreCase( GlobalIds.ALL ) != 0 )
-            {
-                if ( dayMask.length() > DAYMASK_LEN || checkMask( dayMask ) )
-                {
-                    String error = "dayMask - invalid dayMask value [" + dayMask + "]";
-                    throw new ValidationException( GlobalErrIds.CONST_DAYMASK_INVLD, error );
-                }
-            }
-        }
-        else
-        {
-            String error = "dayMask - null or empty dayMask value";
-            throw new ValidationException( GlobalErrIds.CONST_DAYMASK_NULL, error );
-        }
-    }
-
-
-    /**
-     * @param time
-     * @return boolean
-     */
-    private static boolean checkTime( String time )
-    {
-        try
-        {
-            synchronized ( TIME_FORMATER )
-            {
-                TIME_FORMATER.parse( time );
-                return false;
-            }
-        }
-        catch ( ParseException pe )
-        {
-            String error = "checkTime - time [" + time + "] failed validation with ParseException=" + pe;
-            LOG.warn( error );
-            return true;
-        }
-    }
-
-
-    /**
-     * @param date
-     * @return boolean
-     */
-    private static boolean checkDate( String date )
-    {
-        try
-        {
-            synchronized ( DATE_FORMATER )
-            {
-                DATE_FORMATER.parse( date );
-                return false;
-            }
-        }
-        catch ( ParseException pe )
-        {
-            String error = "checkDate - date [" + date + "] failed validation with ParseException=" + pe;
-            LOG.warn( error );
-
-            return true;
-        }
-    }
-
-
-    /**
-     * @param mask
-     * @return boolean
-     */
-    private static boolean checkMask( String mask )
-    {
-        for ( char c : mask.toCharArray() )
-        {
-            if ( ( c < SUNDAY ) || ( c > SATURDAY ) )
-            {
-                String error = "checkMask - mask [" + mask + "] failed validation";
-                LOG.warn( error );
-
-                return true;
-            }
-        }
-
-        return false;
-    }
-
-
-    /**
-     * Method will throw exception with supplied error id and object.method name if object reference is null.
-     *
-     * @param obj       contains the reference to check.
-     * @param errorCode contains the error id to use if null.
-     * @param method contains the method name of caller.
-     * @throws ValidationException in the event object is null.
-     */
-    public static void assertNotNull( Object obj, int errorCode, String method )
-        throws ValidationException
-    {
-        if ( obj == null )
-        {
-            String error = "assertContext detected null entity for method [" + method + "], error code ["
-                + errorCode + "]";
-            throw new ValidationException( errorCode, error );
-        }
-    }
-
-
-    /**
-     * Method will throw exception with supplied error id and object.method name if string reference is null or empty.
-     *
-     * @param value     contains the reference to check.
-     * @param errorCode contains the error id to use if null.
-     * @param method contains the method name of caller.
-     * @throws ValidationException in the event supplied string is null or empty.
-     */
-    public static void assertNotNullOrEmpty( String value, int errorCode, String method )
-        throws ValidationException
-    {
-        if ( !StringUtils.isNotEmpty( value ) )
-        {
-            String error = "assertContext detected null entity for method [" + method + "], error code ["
-                + errorCode + "]";
-            throw new ValidationException( errorCode, error );
-        }
-    }
-
-
-    /**
-     * Method will throw exception with supplied error id and object.method name if string reference is null or empty.
-     *
-     * @param value     contains the reference to check.
-     * @param errorCode contains the error id to use if null.
-     * @param method contains the method name of caller.
-     * @throws ValidationException in the event supplied string is null or empty.
-     */
-    public static void assertNotNullOrEmpty( char[] value, int errorCode, String method )
-        throws ValidationException
-    {
-        if ( !isNotNullOrEmpty( value ) )
-        {
-            String error = "assertContext detected null entity for method [" + method + "], error code ["
-                + errorCode + "]";
-            throw new ValidationException( errorCode, error );
-        }
-    }
-
-
-    /**
-     * Method will return true if string array reference is not null or empty.
-     *
-     * @param value contains the reference to string array.
-     * @return boolean if validation succeeds.
-     */
-    public static boolean isNotNullOrEmpty( String[] value )
-    {
-        return ( value != null ) && ( value.length > 0 );
-    }
-
-
-    /**
-     * Method will return true if string reference is not null or empty.
-     *
-     * @param value contains the reference to string.
-     * @return boolean if validation succeeds.
-     */
-    public static boolean isNotNullOrEmpty( char[] value )
-    {
-        return ( value != null ) && ( value.length > 0 );
-    }
-
-
-    /**
-     * Method will return true if list is not null or empty.
-     *
-     * @param list contains the reference to list.
-     * @return boolean if validation succeeds.
-     */
-    public static boolean isNotNullOrEmpty( Collection<?> list )
-    {
-        return ( list != null ) && ( list.size() > 0 );
-    }
-
-
-    /**
-     * Method will return true if props is not null or empty.
-     *
-     * @param props contains the reference to props.
-     * @return boolean if validation succeeds.
-     */
-    public static boolean isNotNullOrEmpty( Properties props )
-    {
-        return ( props != null ) && ( props.size() > 0 );
-    }
-
-
-    /**
-     * Method will return true if input is not null or empty.
-     *
-     * @param iVal contains the reference to Integer variable.
-     * @return boolean if validation succeeds.
-     */
-    public static boolean isNotNullOrEmpty( Integer iVal )
-    {
-        return ( iVal != null );
-    }
-
-
-    /**
-     * Method will return true if input is not null or empty.
-     *
-     * @param bVal contains the reference to Boolean variable.
-     * @return boolean if validation succeeds.
-     */
-    public static boolean isNotNullOrEmpty( Boolean bVal )
-    {
-        return ( bVal != null );
-    }
-
-
-    /**
-     * Method will return true if byte array reference is not null or empty.
-     *
-     * @param value contains the reference to byte array.
-     * @return boolean if validation succeeds.
-     */
-    public static boolean isNotNullOrEmpty( byte[] value )
-    {
-        boolean result = false;
-        if ( value != null && value.length > 0 )
-        {
-            result = true;
-        }
-        return result;
-    }
-}

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/main/java/org/apache/directory/fortress/core/util/time/CUtil.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/util/time/CUtil.java b/src/main/java/org/apache/directory/fortress/core/util/time/CUtil.java
index 9e8bc20..e2735e1 100755
--- a/src/main/java/org/apache/directory/fortress/core/util/time/CUtil.java
+++ b/src/main/java/org/apache/directory/fortress/core/util/time/CUtil.java
@@ -31,7 +31,8 @@ import org.apache.directory.fortress.core.util.ClassUtil;
 import org.apache.directory.fortress.core.model.Session;
 import org.apache.directory.fortress.core.model.UserRole;
 import org.apache.directory.fortress.core.model.Warning;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -231,7 +232,7 @@ public class CUtil
     public static void validate( Constraint c1 )
         throws ValidationException
     {
-        if ( VUtil.isNotNullOrEmpty( c1.getTimeout() ) )
+        if ( ObjUtil.isNotNullOrEmpty( c1.getTimeout() ) )
         {
             VUtil.timeout( c1.getTimeout() );
         }
@@ -279,11 +280,11 @@ public class CUtil
         throws ValidationException
     {
         //VUtil.timeout(trgC.getTimeout());
-        if ( VUtil.isNotNullOrEmpty( trgC.getTimeout() ) )
+        if ( ObjUtil.isNotNullOrEmpty( trgC.getTimeout() ) )
         {
             srcC.setTimeout( trgC.getTimeout() );
         }
-        else if ( VUtil.isNotNullOrEmpty( srcC.getTimeout() ) )
+        else if ( ObjUtil.isNotNullOrEmpty( srcC.getTimeout() ) )
         {
             trgC.setTimeout( srcC.getTimeout() );
         }
@@ -445,8 +446,8 @@ public class CUtil
             return;
         }
         // no need to continue if the role list is empty and we're trying to check role constraints:
-        else if ( type == ConstraintType.ROLE && !VUtil.isNotNullOrEmpty( session.getRoles() )
-            && !VUtil.isNotNullOrEmpty( session.getAdminRoles() ) )
+        else if ( type == ConstraintType.ROLE && !ObjUtil.isNotNullOrEmpty( session.getRoles() )
+            && !ObjUtil.isNotNullOrEmpty( session.getAdminRoles() ) )
         {
             if ( LOG.isDebugEnabled() )
             {
@@ -471,7 +472,7 @@ public class CUtil
             // Check the constraints for each role assignment:
             else
             {
-                if ( VUtil.isNotNullOrEmpty( session.getRoles() ) )
+                if ( ObjUtil.isNotNullOrEmpty( session.getRoles() ) )
                 {
                     // now check the constraint on every rbac role activation candidate contained within session object:
                     ListIterator<UserRole> roleItems = session.getRoles().listIterator();
@@ -492,7 +493,7 @@ public class CUtil
                         }
                     }
                 }
-                if ( VUtil.isNotNullOrEmpty( session.getAdminRoles() ) )
+                if ( ObjUtil.isNotNullOrEmpty( session.getAdminRoles() ) )
                 {
                     // now check the constraint on every arbac role activation candidate contained within session object:
                     ListIterator roleItems = session.getAdminRoles().listIterator();
@@ -516,7 +517,7 @@ public class CUtil
 
         // now perform DSD validation on session's rbac roles:
         if ( checkDsd && DSDVALIDATOR != null && DSDVALIDATOR.length() > 0 && type == ConstraintType.ROLE
-            && VUtil.isNotNullOrEmpty( session.getRoles() ) )
+            && ObjUtil.isNotNullOrEmpty( session.getRoles() ) )
         {
             Validator dsdVal = ( Validator ) ClassUtil.createInstance( DSDVALIDATOR );
             dsdVal.validate( session, session.getUser(), null );

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/test/java/org/apache/directory/fortress/core/AccelMgrConsole.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/directory/fortress/core/AccelMgrConsole.java b/src/test/java/org/apache/directory/fortress/core/AccelMgrConsole.java
index 0b8c945..1413c3b 100644
--- a/src/test/java/org/apache/directory/fortress/core/AccelMgrConsole.java
+++ b/src/test/java/org/apache/directory/fortress/core/AccelMgrConsole.java
@@ -27,7 +27,7 @@ import org.apache.directory.fortress.core.model.UserRole;
 
 import java.util.List;
 
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/test/java/org/apache/directory/fortress/core/AccessMgrConsole.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/directory/fortress/core/AccessMgrConsole.java b/src/test/java/org/apache/directory/fortress/core/AccessMgrConsole.java
index 180bf1e..902a897 100755
--- a/src/test/java/org/apache/directory/fortress/core/AccessMgrConsole.java
+++ b/src/test/java/org/apache/directory/fortress/core/AccessMgrConsole.java
@@ -31,7 +31,7 @@ import java.util.Comparator;
 import java.util.Enumeration;
 import java.util.List;
 
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/test/java/org/apache/directory/fortress/core/AdminMgrConsole.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/directory/fortress/core/AdminMgrConsole.java b/src/test/java/org/apache/directory/fortress/core/AdminMgrConsole.java
index 9ad54ee..6b83c23 100755
--- a/src/test/java/org/apache/directory/fortress/core/AdminMgrConsole.java
+++ b/src/test/java/org/apache/directory/fortress/core/AdminMgrConsole.java
@@ -36,7 +36,8 @@ import org.apache.directory.fortress.core.rbac.TestUtils;
 import org.apache.directory.fortress.core.model.Permission;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.UserRole;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.apache.directory.fortress.core.util.time.Constraint;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -408,7 +409,7 @@ class AdminMgrConsole
             ue.setMobile("444-222-3333");
 */
             User ue2 = am.addUser(ue);
-            if(VUtil.isNotNullOrEmpty( ue.getRoles() ) )
+            if( ObjUtil.isNotNullOrEmpty( ue.getRoles() ) )
             {
                 for(UserRole uRole : ue.getRoles())
                 {

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/test/java/org/apache/directory/fortress/core/DelegatedAccessMgrConsole.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/directory/fortress/core/DelegatedAccessMgrConsole.java b/src/test/java/org/apache/directory/fortress/core/DelegatedAccessMgrConsole.java
index 3638147..09d1090 100755
--- a/src/test/java/org/apache/directory/fortress/core/DelegatedAccessMgrConsole.java
+++ b/src/test/java/org/apache/directory/fortress/core/DelegatedAccessMgrConsole.java
@@ -25,7 +25,7 @@ import org.apache.directory.fortress.core.model.Role;
 import org.apache.directory.fortress.core.rbac.TestUtils;
 import org.apache.directory.fortress.core.model.User;
 import org.apache.directory.fortress.core.model.Session;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;

http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/0e307ed6/src/test/java/org/apache/directory/fortress/core/GroupMgrConsole.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/directory/fortress/core/GroupMgrConsole.java b/src/test/java/org/apache/directory/fortress/core/GroupMgrConsole.java
index db2de58..7a3f53e 100755
--- a/src/test/java/org/apache/directory/fortress/core/GroupMgrConsole.java
+++ b/src/test/java/org/apache/directory/fortress/core/GroupMgrConsole.java
@@ -20,13 +20,15 @@
 package org.apache.directory.fortress.core;
 
 import org.apache.commons.lang.StringUtils;
-import org.apache.directory.fortress.core.ldap.group.Group;
+import org.apache.directory.fortress.core.model.Group;
 import org.apache.directory.fortress.core.ldap.group.GroupMgr;
 import org.apache.directory.fortress.core.ldap.group.GroupMgrFactory;
-import org.apache.directory.fortress.core.util.attr.VUtil;
+import org.apache.directory.fortress.core.model.VUtil;
 
 import java.util.Enumeration;
 import java.util.List;
+
+import org.apache.directory.fortress.core.util.ObjUtil;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -251,7 +253,7 @@ class GroupMgrConsole
             System.out.println("    name        [" + outGroup.getName() + "]");
             System.out.println("    desc        [" + outGroup.getDescription() + "]");
             System.out.println("    protocol    [" + outGroup.getProtocol() + "]");
-            if ( VUtil.isNotNullOrEmpty( outGroup.getMembers() ) )
+            if ( ObjUtil.isNotNullOrEmpty( outGroup.getMembers() ) )
             {
                 int ctr = 0;
                 for (String member : outGroup.getMembers() )
@@ -259,7 +261,7 @@ class GroupMgrConsole
                     System.out.println("    member[" + ctr++ + "]=" + member);
                 }
             }
-            if ( VUtil.isNotNullOrEmpty( outGroup.getProperties() ) )
+            if ( ObjUtil.isNotNullOrEmpty( outGroup.getProperties() ) )
             {
                 int ctr = 0;
                 for (Enumeration e = outGroup.getProperties().propertyNames(); e.hasMoreElements();)
@@ -289,7 +291,7 @@ class GroupMgrConsole
             Group inGroup = new Group( ReaderUtil.readLn() );
 
             List<Group> outGroups = groupMgr.find( inGroup );
-            if(VUtil.isNotNullOrEmpty( outGroups ))
+            if(ObjUtil.isNotNullOrEmpty( outGroups ))
             {
                 int grpctr = 0;
                 for( Group outGroup : outGroups )
@@ -298,7 +300,7 @@ class GroupMgrConsole
                     System.out.println("    name        [" + outGroup.getName() + "]");
                     System.out.println("    desc        [" + outGroup.getDescription() + "]");
                     System.out.println("    protocol    [" + outGroup.getProtocol() + "]");
-                    if ( VUtil.isNotNullOrEmpty( outGroup.getMembers() ) )
+                    if ( ObjUtil.isNotNullOrEmpty( outGroup.getMembers() ) )
                     {
                         int memberctr = 0;
                         for (String member : outGroup.getMembers() )
@@ -306,7 +308,7 @@ class GroupMgrConsole
                             System.out.println("    member[" + memberctr++ + "]=" + member);
                         }
                     }
-                    if ( VUtil.isNotNullOrEmpty( outGroup.getProperties() ) )
+                    if ( ObjUtil.isNotNullOrEmpty( outGroup.getProperties() ) )
                     {
                         int propctr = 0;
                         for (Enumeration e = outGroup.getProperties().propertyNames(); e.hasMoreElements();)


Mime
View raw message