Package com.google.gwt.dev.jjs.test.StaticObject

Examples of com.google.gwt.dev.jjs.test.StaticObject.InstanceObject.foo()


  public void testJsniConstructors() {
    StaticObject o = staticArg(1);
    assertEquals(1, o.foo());

    InstanceObject i = instanceArg(o, 1);
    assertEquals(o.foo() + 1, i.foo());

    NestedInstanceObject n = nestedInstanceArg(i, 1);
    assertEquals(i.foo() + 1, n.foo());

    StaticInnerObject inner = staticInnerArg(3);
View Full Code Here


    InstanceObject i = instanceArg(o, 1);
    assertEquals(o.foo() + 1, i.foo());

    NestedInstanceObject n = nestedInstanceArg(i, 1);
    assertEquals(i.foo() + 1, n.foo());

    StaticInnerObject inner = staticInnerArg(3);
    assertEquals(3, inner.foo());

    NoArgObject noArg = noArg();
View Full Code Here

    StaticObject o2 = passAndReturnStatic(6);
    assertEquals(6, o2.foo());

    InstanceObject i2 = passAndReturnInstance(o2, 1);
    assertEquals(o2.foo() + 1, i2.foo());
  }

  private native InstanceObject instanceArg(StaticObject obj, int i) /*-{
    return @com.google.gwt.dev.jjs.test.StaticObject.InstanceObject::new(Lcom/google/gwt/dev/jjs/test/StaticObject;I)(obj,i);
  }-*/;
 
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.