public static synchronized JS parseReader(Reader r) throws IOException {
CharStream cs = new CharStream(r);
public static synchronized JS parseReader(Reader r) throws IOException {
CharStream cs = new CharStream(r);
Object[] ids = h.keys();
for(int i=0; i<ids.length; i++) {
Object el = h.get((String)ids[i]);
if (el instanceof JS && "html".equals(((JS)el).get("$name")))
return (JS)el;
}
Object[] ids = h.keys();
for(int i=0; i<ids.length; i++) {
Object el = h.get((String)ids[i]);
if (el instanceof JS && "html".equals(((JS)el).get("$name")))
return (JS)el;
}
closetag = parseElement(cs, kid);
h.put(String.valueOf(length), kid);
h.put("$numchildren", new Integer(++length));
closetag = parseElement(cs, kid);
h.put(String.valueOf(length), kid);
h.put("$numchildren", new Integer(++length));