code: private boolean isMemberRecurse(Principal principal, Vector<Principal> vector)
     {
         for(Enumeration<Principal> enumeration = members(); enumeration.hasMoreElements();)
         {
             boolean flag = false;
             Principal principal1 = (Principal)enumeration.nextElement();
             if(principal1.equals(principal))
                 return true;
             if(principal1 instanceof SecurityGroup)
             {
                SecurityGroup groupimpl = (SecurityGroup)principal1;
                 vector.addElement(this);
                 if(!vector.contains(groupimpl))
                     flag = groupimpl.isMemberRecurse(principal, vector);
             } 
             else
             if(principal1 instanceof SecurityGroup)
             {
          	   SecurityGroup group1 = (SecurityGroup)principal1;
                 if(!vector.contains(group1))
                     flag = group1.isMember(principal);
             }
  
             if(flag)
                 return flag;
         }
  
         return false;
     }
docs: --------------------------------------------