public org.omg.CORBA.portable.OutputStream _invoke (String $method,
                                org.omg.CORBA.portable.InputStream in,
                                org.omg.CORBA.portable.ResponseHandler $rh)
  {
    org.omg.CORBA.portable.OutputStream out = null;
    java.lang.Integer __method = (java.lang.Integer)_methods.get ($method);
    if (__method == null)
      throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE);

    switch (__method.intValue ())
    {
       case 0:  // pgrid/service/corba/exchange/ExchangeHandle/_get_routingTable
       {
         pgrid.service.corba.CorbaRoutingTable $result = null;
         $result = this.routingTable ();
         out = $rh.createReply();
         pgrid.service.corba.CorbaRoutingTableHelper.write (out, $result);
         break;
       }

       case 1:  // pgrid/service/corba/exchange/ExchangeHandle/exchange
       {
         pgrid.service.corba.CorbaRoutingTable routingTable = pgrid.service.corba.CorbaRoutingTableHelper.read (in);
         this.exchange (routingTable);
         out = $rh.createReply();
         break;
       }

       default:
         throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE);
    }

    return out;
  } // _invoke