Package com.google.gwt.dev.shell.BrowserChannel

Examples of com.google.gwt.dev.shell.BrowserChannel.InvokeOnClientMessage


    Value[] args = new Value[] {
      new Value(), new Value(),
    };
    args[0].setInt(0);
    args[1].setInt(1);
    new InvokeOnClientMessage(channel, methodName, thisRef, args).send();
    MessageType type = channel.readMessageType();
    assertEquals(MessageType.INVOKE, type);
    InvokeOnClientMessage message = InvokeOnClientMessage.receive(channel);
    assertEquals(methodName, message.getMethodName());
    Value thisRefRecv = message.getThis();
    assertEquals(ValueType.JAVA_OBJECT, thisRefRecv.getType());
    assertEquals(42, thisRefRecv.getJavaObject().getRefid());
    Value[] argsRecv = message.getArgs();
    assertEquals(2, argsRecv.length);
    for (int i = 0; i < 2; ++i) {
      assertEquals(ValueType.INT, argsRecv[i].getType());
      assertEquals(i, argsRecv[i].getInt());
    }
View Full Code Here

TOP

Related Classes of com.google.gwt.dev.shell.BrowserChannel.InvokeOnClientMessage

Copyright © 2018 www.massapicom. 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.