start = Math.max(start, 0); length = Math.min(list.size() - start, length);
    public Scriptable jsFunction_list(Object startArg, Object lengthArg) {        if (startArg == Undefined.instance && lengthArg == Undefined.instance) {            return list();        }        int start = (int) ScriptRuntime.toNumber(startArg);        int length = (int) ScriptRuntime.toNumber(lengthArg);        if (start < 0 || length < 0) {            throw new EvaluatorException("Arguments must not be negative in HopObject.list(start, length)");        }        checkNode();        prefetchChildren(start, length);        ArrayList a = new ArrayList();        for (int i=start; i<start+length; i++) {            NodeHandle nh = (NodeHandle) list.get(i);            if (nh != null)                a.add(Context.toObject(nh.getNode(wnm), core.global));        }        return Context.getCurrentContext().newArray(core.global, a.toArray());    }