Package org.jamesii.core.remote.hostcentral

Examples of org.jamesii.core.remote.hostcentral.HostCentralIDFactory.create()


  }

  public void testObjectRegistration() {
    HostCentralIDFactory idFac = new HostCentralIDFactory();
    d = new Dummy();
    id = idFac.create(new ParameterBlock(d, HostCentralIDFactory.PARAM_OBJECT), SimSystem.getRegistry().createContext());
    assertTrue(null != id);

    IObjectId id2 =
        new BasicRemoteObjectId(id.getStringRep(), d.getClass().getName());
View Full Code Here


  }

  public void testLocalMethodCalling() {
    HostCentralIDFactory idFac = new HostCentralIDFactory();
    d = new Dummy();
    id = idFac.create(new ParameterBlock(d, HostCentralIDFactory.PARAM_OBJECT), SimSystem.getRegistry().createContext());
    lcc.registerObject(id, d);
    Object o = lcc.executeMethod(Dummy.ONLY_METHOD, null, id);
    assertEquals(Dummy.RESULT, o);
  }
View Full Code Here

   */
  public void testIDcreation() {
    HostCentralIDFactory hcIDfac = new HostCentralIDFactory();
    Object o = new Object();
    ParameterBlock p = new ParameterBlock(o, HostCentralIDFactory.PARAM_OBJECT);
    IObjectId id = hcIDfac.create(p, SimSystem.getRegistry().createContext());
    IObjectId id2 =
        new BasicRemoteObjectId(id.getStringRep(), o.getClass().getName());

    // System.out.println(id.getStringRep());
    // System.out.println(id2.getStringRep());
View Full Code Here

    }
    System.out.println("Registry initiliazed");
    // Registering an object here.
    HostCentralIDFactory idFac = new HostCentralIDFactory();
    d = new Dummy();
    id = idFac.create(new ParameterBlock(d, HostCentralIDFactory.PARAM_OBJECT), SimSystem.getRegistry().createContext());
    try {
      rcc.registerLocalObject(id, d);
    } catch (RemoteException e) {
      e.printStackTrace();
      return;
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.