code: public static Object add(Object list, Object item)
      {
          if (list==null)
          {
              if (item instanceof List || item==null)
              {
                  List l = new ArrayList();
                  l.add(item);
                  return l;
              }
  
              return item;
          }
  
          if (list instanceof List)
          {
              ((List)list).add(item);
              return list;
          }
  
          List l=new ArrayList();
          l.add(list);
          l.add(item);
          return l;    
      }
docs: Add an item to a LazyList
  @param list The list to add to or null if none yet created.
  @param item The item to add.
  @return The lazylist created or added to.