Examples of self()


Examples of anvil.codec.Code.self()

    anvil.util.Conversions.toString(clsid, cal);
    Field clsidfield = clazz.createField("_id", "Ljava/lang/String;", ACC_PUBLIC|ACC_STATIC|ACC_FINAL);
    clsidfield.setConstantValue(pool.addString(clsid.toString()));

    context.pushCode(code);
    code.self();
    code.invokespecial(pool.addMethodRef("anvil/script/compiler/CompiledModule",
      "<init>", "()V"));
    context.popCode();
   
    Method versionmethod = clazz.createMethod("getVersion", "()I", ACC_PUBLIC);
View Full Code Here

Examples of com.ericsson.otp.erlang.OtpMbox.self()

        final OtpErlangAtom gleader = USER_ATOM;
        try {
            final Object[] args1 = new Object[args.length + 1];
            System.arraycopy(args, 0, args1, 1, args.length);
            final OtpMbox mbox = localNode.createMbox();
            args1[0] = mbox.self();
            new RpcResultReceiver(mbox, cb);
            rpcCast(localNode, nodeName, false, gleader, m, f, signature, args1);
        } catch (final SignatureException e) {
            throw new RpcException(e);
        }
View Full Code Here

Examples of com.ericsson.otp.erlang.OtpMbox.self()

        final OtpErlangObject[] args = convertArgs(signature, args0);

        OtpErlangObject res = null;
        final OtpMbox mbox = node.createMbox();
        res = buildRpcCall(mbox.self(), gleader, module, fun, args);
        if (logCalls) {
            final Object[] args01 = { module, fun, argString(args) };
            ErlLogger.debug("call -> %s:%s(%s)", args01);
        }
        //
View Full Code Here

Examples of com.ericsson.otp.erlang.OtpMbox.self()

          : new Object[0]);
      Method jmethod = ((JavaOperation) msg.getOperation())
          .getJavaMethod();
      // create and send msg with self pid in the beginning
      OtpErlangObject[] argsArray = {
          tmpMbox.self(),
          TypeHelpersProxy.toErlang(args, jmethod
              .getParameterAnnotations()) };
      OtpErlangObject otpArgs = new OtpErlangTuple(argsArray);
      tmpMbox.send(msg.getOperation().getName(), binding.getNode(),
          otpArgs);
View Full Code Here

Examples of com.ericsson.otp.erlang.OtpMbox.self()

    if (o == null) System.exit(6);
    if(!((OtpErlangAtom)o).equals(msgArray[1])) System.exit(7);

    // Test2: Sending message between mboxes on same node
    // given registered name and node with host.
    mbox.send("java_echo_server2",mbox2.self().node(),msgArray[1]);
    o = mbox2.receive(recTime);
    dbg("Mbox at same node: " + o);
    if (o == null) System.exit(8);
    if(!((OtpErlangAtom)o).equals(msgArray[1])) System.exit(9);
View Full Code Here

Examples of com.ericsson.otp.erlang.OtpMbox.self()

    if (o == null) System.exit(10);
    if(!((OtpErlangAtom)o).equals(msgArray[1])) System.exit(11);

    // Test4: Sending message between mboxes on same node
    // given pid.
    mbox.send(mbox2.self(),msgArray[1]);
    o = mbox2.receive(recTime);
    dbg("Mbox at same node: " + o);
    if (o == null) System.exit(12);
    if(!((OtpErlangAtom)o).equals(msgArray[1])) System.exit(13);
View Full Code Here

Examples of com.ericsson.otp.erlang.OtpMbox.self()

    if (o == null) System.exit(14);
    if(!((OtpErlangAtom)o).equals(msgArray[1])) System.exit(15);

    // Test2: Sending message between mboxes on different
    // nodes given registered name and node with host.
    mbox.send("mboxOtherNode",mboxOtherNode.self().node(),
        msgArray[1]);
    o = mboxOtherNode.receive(recTime);
    dbg("Mbox at same node: " + o);
    if (o == null) System.exit(16);
    if(!((OtpErlangAtom)o).equals(msgArray[1])) System.exit(17);
View Full Code Here

Examples of com.ericsson.otp.erlang.OtpMbox.self()

    if (o == null) System.exit(16);
    if(!((OtpErlangAtom)o).equals(msgArray[1])) System.exit(17);

    // Test3: Sending message between mboxes on different
    // nodes given pid.
    mbox.send(mboxOtherNode.self(),msgArray[1]);
    o = mboxOtherNode.receive(recTime);
    dbg("Mbox at same node: " + o);
    if (o == null) System.exit(18);
    if(!((OtpErlangAtom)o).equals(msgArray[1])) System.exit(19);
View Full Code Here

Examples of com.ericsson.otp.erlang.OtpMbox.self()

      // Announce our presence
      final OtpErlangObject[] amsg = new OtpErlangObject[3];
      amsg[0] = new OtpErlangAtom("echo_server");
      amsg[1] = new OtpErlangAtom(argv[0]);
      amsg[2] = mbox.self();
      final OtpErlangTuple atuple = new OtpErlangTuple(amsg);
      mbox.send(argv[3], argv[2], atuple);

      // Do echoing...
      while (true) {
View Full Code Here

Examples of com.ericsson.otp.erlang.OtpMbox.self()

        .elementAt(0);
      if (debug) System.out.println("Echoing: "
                  + msg.elementAt(1));

      final OtpErlangObject[] rmsg = new OtpErlangObject[2];
      rmsg[0] = mbox.self();
      rmsg[1] = msg.elementAt(1);
      final OtpErlangTuple rtuple = new OtpErlangTuple(rmsg);

      mbox.send(from, rtuple);
      continue;
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.