code: public static Collection<Object> toCollectionMap(Collection<?> aCollection)
     throws Exception
     {
        if(aCollection == null )
           return null;
           
        List<Object> listMap = new ArrayList<Object>(aCollection.size());  
  
        Object nestedObj = null;
        for(Iterator<?> i= aCollection.iterator();i.hasNext();)
        {
                  
            nestedObj = i.next();
              listMap.add(toNestedMap(nestedObj));
        }
                
        return listMap;
     }
docs: ---------------------------------------------------------------------