static Test() { clazz = JClass.ForName ("Test"); _ctr = clazz.GetConstructor (); _foo = clazz.GetMethod ("foo", "(LControllable;)V"); _bar = clazz.GetMethod ("bar", "()LControllable;"); }
internal JField(JClass declaringClass, string name, string sig, bool isStatic, IntPtr methodID) : base(methodID) { this.declaringClass = declaringClass; this.name = name; this.isStatic = isStatic; }
internal JMethod(JClass declaringClass, string name, string sig, bool isStatic, IntPtr methodID) : base(methodID) { this.declaringClass = declaringClass; this.name = name; this.isStatic = isStatic; this.sig = sig; this.rType = JMethodReturnType.INVALID; }
static Prog() { clazz = JClass.ForName ("Prog"); _ctr = clazz.GetConstructor (); _max = clazz.GetMethod ("max", "(II)I"); _maxEx = clazz.GetMethod ("maxEx", "()I"); _hi = clazz.GetStaticMethod ("hi", "()V"); _foo = clazz.GetMethod ("foo", "()LProg;"); _fooA = clazz.GetMethod ("fooA", "()[LProg;"); _fooB = clazz.GetMethod ("fooB", "([LProg;)I"); _fooC = clazz.GetMethod ("fooC", "()[I"); _foo9 = clazz.GetMethod ("foo9", "([I)I"); _foo10 = clazz.GetMethod ("foo10", "([C)[C"); }
public JObjectArray(JObject[] source, JClass clazz) : this(source.Length, clazz) { int l = source.Length; for (int i = 0; i < l; i++) { JObject o = source[i]; if (o != null) { SetObjectArrayElement (this.Handle, i, o.Handle); } } // TODO ArrayIndexOutOfBoundsException // TODO ArrayStoreException JThrowable.CheckAndThrow (); }
public bool IsAssignableFrom(JClass other) { return IsAssignableFrom (this.Handle, other.Handle); }
public JObjectArray(int length, JClass clazz) : base(NewObjectArray (length, clazz.Handle, IntPtr.Zero)) { // out of memory JThrowable.CheckAndThrow (); }
static ControllableJNIImpl() { clazz = JClass.ForName ("Controllable"); _control = clazz.GetMethod ("control", "()V"); }
static Template() { clazz = JClass.ForName ("Template"); _getInstance = clazz.GetStaticMethod ("getInstance", "()LTemplate;"); _foo = clazz.GetMethod ("foo", "(LTemplate;)V"); }
static TemplateJNIImpl() { clazz = JClass.ForName ("Template"); _bar = clazz.GetMethod ("bar", "()V"); }
internal JConstructor(JClass declaringClass, IntPtr methodID) : base(methodID) { this.declaringClass = declaringClass; }