3 /** anything that is callable with the () operator and wasn't compiled from JS code */
4 public abstract class JSCallable extends JS {
6 // return this from get() if the key was actually a method.
7 public static final Object METHOD = new Object();
9 public Object callMethod(Object method, Object a0, Object a1, Object a2, Object[] rest, int nargs) {
10 throw new JS.Exn("attempted to call an undefined method");
13 public Object call(Object a0, Object a1, Object a2, Object[] rest, int nargs) {
14 throw new JS.Exn("you cannot call this object");