⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 _clientstub.java

📁 直接放在eclipse环境下
💻 JAVA
📖 第 1 页 / 共 3 页
字号:
			_result = _localServant.disconnect(name,ck);
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return _result;
		}
		}
	}
	public org.omg.Components.FacetDescription[] get_all_facets()	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "get_all_facets", true);
				_is = _invoke(_os);
				org.omg.Components.FacetDescription[] _result = org.omg.Components.FacetDescriptionsHelper.read(_is);
				return _result;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "get_all_facets", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			org.omg.Components.FacetDescription[] _result;			try
			{
			_result = _localServant.get_all_facets();
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return _result;
		}
		}
	}
	public org.omg.Components.Cookie connect(java.lang.String name, org.omg.CORBA.Object connection) throws org.omg.Components.AlreadyConnected,org.omg.Components.InvalidConnection,org.omg.Components.ExceededConnectionLimit,org.omg.Components.InvalidName	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "connect", true);
				_os.write_string(name);
				_os.write_Object(connection);
				_is = _invoke(_os);
				org.omg.Components.Cookie _result = (org.omg.Components.Cookie)((org.omg.CORBA_2_3.portable.InputStream)_is).read_value ("IDL:omg.org/Components/Cookie:1.0");
				return _result;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				if( _id.equals("IDL:omg.org/Components/AlreadyConnected:1.0"))
				{
					throw org.omg.Components.AlreadyConnectedHelper.read(_ax.getInputStream());
				}
				else if( _id.equals("IDL:omg.org/Components/InvalidConnection:1.0"))
				{
					throw org.omg.Components.InvalidConnectionHelper.read(_ax.getInputStream());
				}
				else if( _id.equals("IDL:omg.org/Components/ExceededConnectionLimit:1.0"))
				{
					throw org.omg.Components.ExceededConnectionLimitHelper.read(_ax.getInputStream());
				}
				else if( _id.equals("IDL:omg.org/Components/InvalidName:1.0"))
				{
					throw org.omg.Components.InvalidNameHelper.read(_ax.getInputStream());
				}
				else 					throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "connect", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			org.omg.Components.Cookie _result;			try
			{
			_result = _localServant.connect(name,connection);
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return _result;
		}
		}
	}
	public org.objectweb.ccm.demo3.Services get_connection_the_service()	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "get_connection_the_service", true);
				_is = _invoke(_os);
				org.objectweb.ccm.demo3.Services _result = org.objectweb.ccm.demo3.ServicesHelper.read(_is);
				return _result;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "get_connection_the_service", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			org.objectweb.ccm.demo3.Services _result;			try
			{
			_result = _localServant.get_connection_the_service();
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return _result;
		}
		}
	}
	public void configuration_complete() throws org.omg.Components.InvalidConfiguration	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "configuration_complete", true);
				_is = _invoke(_os);
				return;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				if( _id.equals("IDL:omg.org/Components/InvalidConfiguration:1.0"))
				{
					throw org.omg.Components.InvalidConfigurationHelper.read(_ax.getInputStream());
				}
				else 					throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "configuration_complete", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			try
			{
			_localServant.configuration_complete();
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return;
		}
		}
	}
	public org.omg.Components.PublisherDescription[] get_all_publishers()	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "get_all_publishers", true);
				_is = _invoke(_os);
				org.omg.Components.PublisherDescription[] _result = org.omg.Components.PublisherDescriptionsHelper.read(_is);
				return _result;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "get_all_publishers", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			org.omg.Components.PublisherDescription[] _result;			try
			{
			_result = _localServant.get_all_publishers();
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return _result;
		}
		}
	}
	public org.omg.Components.EventConsumerBase get_consumer(java.lang.String sink_name) throws org.omg.Components.InvalidName	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "get_consumer", true);
				_os.write_string(sink_name);
				_is = _invoke(_os);
				org.omg.Components.EventConsumerBase _result = org.omg.Components.EventConsumerBaseHelper.read(_is);
				return _result;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				if( _id.equals("IDL:omg.org/Components/InvalidName:1.0"))
				{
					throw org.omg.Components.InvalidNameHelper.read(_ax.getInputStream());
				}
				else 					throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "get_consumer", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			org.omg.Components.EventConsumerBase _result;			try
			{
			_result = _localServant.get_consumer(sink_name);
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return _result;
		}
		}
	}
	public org.omg.Components.CCMHome get_ccm_home()	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "get_ccm_home", true);
				_is = _invoke(_os);
				org.omg.Components.CCMHome _result = org.omg.Components.CCMHomeHelper.read(_is);
				return _result;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "get_ccm_home", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			org.omg.Components.CCMHome _result;			try
			{
			_result = _localServant.get_ccm_home();
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return _result;
		}
		}
	}
	public org.omg.Components.FacetDescription[] get_named_facets(java.lang.String[] names) throws org.omg.Components.InvalidName	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "get_named_facets", true);
				org.omg.Components.NameListHelper.write(_os,names);
				_is = _invoke(_os);
				org.omg.Components.FacetDescription[] _result = org.omg.Components.FacetDescriptionsHelper.read(_is);
				return _result;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				if( _id.equals("IDL:omg.org/Components/InvalidName:1.0"))
				{
					throw org.omg.Components.InvalidNameHelper.read(_ax.getInputStream());
				}
				else 					throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "get_named_facets", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			org.omg.Components.FacetDescription[] _result;			try
			{
			_result = _localServant.get_named_facets(names);
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return _result;
		}
		}
	}
	public org.omg.Components.EventConsumerBase unsubscribe(java.lang.String publisher_name, org.omg.Components.Cookie ck) throws org.omg.Components.InvalidConnection,org.omg.Components.InvalidName	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "unsubscribe", true);
				_os.write_string(publisher_name);
				((org.omg.CORBA_2_3.portable.OutputStream)_os).write_value (ck );
				_is = _invoke(_os);
				org.omg.Components.EventConsumerBase _result = org.omg.Components.EventConsumerBaseHelper.read(_is);
				return _result;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				if( _id.equals("IDL:omg.org/Components/InvalidConnection:1.0"))
				{
					throw org.omg.Components.InvalidConnectionHelper.read(_ax.getInputStream());
				}
				else if( _id.equals("IDL:omg.org/Components/InvalidName:1.0"))
				{
					throw org.omg.Components.InvalidNameHelper.read(_ax.getInputStream());
				}
				else 					throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "unsubscribe", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			org.omg.Components.EventConsumerBase _result;			try
			{
			_result = _localServant.unsubscribe(publisher_name,ck);
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return _result;
		}
		}
	}
	public void connect_consumer(java.lang.String emitter_name, org.omg.Components.EventConsumerBase consumer) throws org.omg.Components.AlreadyConnected,org.omg.Components.InvalidConnection,org.omg.Components.InvalidName	{
		while(true)
		{
		if(! this._is_local())
		{
			org.omg.CORBA.portable.InputStream _is = null;
			try
			{
				org.omg.CORBA.portable.OutputStream _os = _request( "connect_consumer", true);
				_os.write_string(emitter_name);
				org.omg.Components.EventConsumerBaseHelper.write(_os,consumer);
				_is = _invoke(_os);
				return;
			}
			catch( org.omg.CORBA.portable.RemarshalException _rx ){}
			catch( org.omg.CORBA.portable.ApplicationException _ax )
			{
				String _id = _ax.getId();
				if( _id.equals("IDL:omg.org/Components/AlreadyConnected:1.0"))
				{
					throw org.omg.Components.AlreadyConnectedHelper.read(_ax.getInputStream());
				}
				else if( _id.equals("IDL:omg.org/Components/InvalidConnection:1.0"))
				{
					throw org.omg.Components.InvalidConnectionHelper.read(_ax.getInputStream());
				}
				else if( _id.equals("IDL:omg.org/Components/InvalidName:1.0"))
				{
					throw org.omg.Components.InvalidNameHelper.read(_ax.getInputStream());
				}
				else 					throw new RuntimeException("Unexpected exception " + _id );
			}
			finally
			{
				this._releaseReply(_is);
			}
		}
		else
		{
			org.omg.CORBA.portable.ServantObject _so = _servant_preinvoke( "connect_consumer", _opsClass );
			if( _so == null )
				throw new org.omg.CORBA.UNKNOWN("local invocations not supported!");
			ClientOperations _localServant = (ClientOperations)_so.servant;
			try
			{
			_localServant.connect_consumer(emitter_name,consumer);
			}
			finally
			{
				_servant_postinvoke(_so);
			}
			return;
		}
		}
	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -