return cx.toObject(obj, core.global);
return Context.toObject(obj, core.global);
    public Object get(String name, Scriptable start) {        // System.err.println ("GET from "+node+": "+name);        Object retval = super.get(name, start);        if (retval != ScriptableObject.NOT_FOUND) {            return retval;        }        if (prototype != null) {            retval = prototype.get(name, start);        }        if (retval != ScriptableObject.NOT_FOUND) {            return retval;        }        if (node != null) {            // Everything starting with an underscore is interpreted as internal property            if (name.charAt(0) == '_') {                return getInternalProperty(name);            }            IProperty p = node.get(name);            if (p != null) {                if (p.getType() == IProperty.STRING) {                    return p.getStringValue();                }                if (p.getType() == IProperty.BOOLEAN) {                    return p.getBooleanValue() ? Boolean.TRUE : Boolean.FALSE;                }                if (p.getType() == IProperty.INTEGER) {                    return new Long(p.getIntegerValue());                }                if (p.getType() == IProperty.FLOAT) {                    return new Double(p.getFloatValue());                }                Context cx = Context.getCurrentContext();                if (p.getType() == IProperty.DATE) {                    Date d = p.getDateValue();                    if (d == null) {                        return NOT_FOUND;                    } else {                        Object[] args = { new Long(d.getTime()) };                        try {                            return cx.newObject(core.global, "Date", args);                        } catch (PropertyException px) {                            return NOT_FOUND;                        } catch (NotAFunctionException nafx) {                            return NOT_FOUND;                        } catch (JavaScriptException nafx) {                            return NOT_FOUND;                        }                    }                }                if (p.getType() == IProperty.NODE) {                    INode n = p.getNodeValue();                    if (n == null) {                        return NOT_FOUND;                    } else {                        return cx.toObject(n, core.global);                    }                }                if (p.getType() == IProperty.JAVAOBJECT) {                    Object obj = p.getJavaObjectValue();                    if (obj == null) {                        return NOT_FOUND;                    } else {                        return cx.toObject(obj, core.global);                    }                }            }            // as last resort, try to get property as anonymous subnode            Object anon = node.getChildElement(name);            if (anon != null) {                return anon;            }        }        return NOT_FOUND;    }