package run;

import jp.sync.Barrier;

import java.util.Vector;

import jp.lang.*;



import jp.lang.*;

public final class Worker_class_impl extends jp.lang.RemoteObject_class_impl
  implements Worker_class_intf
{

  /** Constructor for class implementation part of class Worker. */
  public Worker_class_impl(boolean isConstructor) throws uka.karmi.rmi.RemoteException {
    super(isConstructor);
  }

  /** Dummy method to achieve type conversion inside an expression 
      between the handle class 'Worker' and the the class implementation 
      'Worker_class_impl'. The argument is not needed. 
      This is only used by the transformation internally.
  */
  private static final Worker_class_impl _ClassType_(Worker x) {
    return null;
  }

  /** Replicated static constant '_class' */
  public static Worker_class_intf _class;

  /** Remote static variable access: get Worker._class */
  public final Worker_class_intf run_Worker__class_get_()  {
    return this._class;
  }

  /** Factory method to calls the constructor Worker_instance_impl(barrier, time, timestep, autostep) 
      on a remote node and passes the result back to the caller. This
      method is used during remote object instantiations on remote nodes.
  */
  public java.lang.Object _new(Barrier barrier, double time, double timestep, boolean autostep) throws uka.karmi.rmi.RemoteException {
    // remote object creation may throw a RemoteException
    // during object export
    Worker_instance_impl _impl = new Worker_instance_impl(barrier, time, timestep, autostep);

    return (java.lang.Object) _impl._getRef();
  }

  /** Code of all static initializers of the class */
  protected void _init() {
  }

  static {
    int _location = RuntimeEnvironment.getMachineID();
    try {
      // Lookup class object for initialization
      // of replicated constants (if already present).
      _class = (Worker_class_intf) RuntimeEnvironment.rm.getClassInitializer("run.Worker", _location);
      if (_class == null) {
        // Class is not yet loaded, load and initialize locally.
        _class = (Worker_class_intf) new Worker_class_impl(false)._getStub();
        RuntimeEnvironment.rm.setClassObject("run.Worker",_class);
      } else {
        // Class was loaded elsewhere, copy replicated constants (if any).
      }
    } catch (uka.karmi.rmi.RemoteException _e) {
      throw new jp.lang.RemoteError("Worker_class_impl.<clinit>()", _e);
    } catch (Exception _e) {
      // ClassNotFoundException, IllegalAccessException, RuntimeException
      _e.printStackTrace();
      throw new InternalError("Worker_class_impl.<clinit>(): " + _e);
    }
  }
}
