package helloWorld;

/**
 * <ul>
 * <li> <b>IDL Source</b>    "HelloWorld.idl"
 * <li> <b>IDL Name</b>      ::helloWorld::GoodDay
 * <li> <b>Repository Id</b> IDL:helloWorld/GoodDay:1.0
 * </ul>
 * <b>IDL definition:</b>
 * <pre>
 * interface GoodDay {
  ...
};
 * </pre>
 */
public class _GoodDayStub extends com.inprise.vbroker.CORBA.portable.ObjectImpl implements helloWorld.GoodDay {
  final public static java.lang.Class _opsClass = helloWorld.GoodDayOperations.class;

  public java.lang.String[] _ids () {
    return __ids;
  }

  private static java.lang.String[] __ids = {
    "IDL:helloWorld/GoodDay:1.0"
  };

  /**
   * <pre>
   *   string hello ();
   * </pre>
   */
  public java.lang.String hello () {

    while (true) {
      if (!_is_local()) {
        org.omg.CORBA.portable.OutputStream _output = null;
        org.omg.CORBA.portable.InputStream  _input  = null;
        java.lang.String _result;
        try {
          _output = this._request("hello", true);
          _input = this._invoke(_output);
          _result = _input.read_string();
          return _result;
        }
        catch (org.omg.CORBA.portable.ApplicationException _exception) {
          final org.omg.CORBA.portable.InputStream in = _exception.getInputStream();
          java.lang.String _exception_id = _exception.getId();
          throw new org.omg.CORBA.UNKNOWN("Unexpected User Exception: " + _exception_id);
        }
        catch (org.omg.CORBA.portable.RemarshalException _exception) {
          continue;
        }
        finally {
          this._releaseReply(_input);
        }
      } else {
        final org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke("hello", _opsClass);
        if (_so == null) {
          continue;
        }
        final helloWorld.GoodDayOperations _self = (helloWorld.GoodDayOperations)_so.servant;
        try {
          return _self.hello();
        }
        finally {
          _servant_postinvoke(_so);
        }
      }
    }
  }

}
