code: public static List getList(Object list, boolean nullForEmpty)
      {
          if (list==null)
              return nullForEmpty?null:Collections.EMPTY_LIST;
          if (list instanceof List)
              return (List)list;
          
          List l = new ArrayList(1);
          l.add(list);
          return l;
      }
docs: Get the real List from a LazyList.
  
  @param list A LazyList returned from LazyList.add(Object) or null
  @param nullForEmpty If true, null is returned instead of an
  empty list.
  @return The List of added items, which may be null, an EMPTY_LIST
  or a SingletonList.