[omniORB] Unimplemented interfaces - could they remain undefined

Ivanov, Roumen Roumen.Ivanov@dresdner-bank.com
Thu, 26 Oct 2000 16:02:52 +0200


Hi,
I have an interface definition whose implementations will differ in exposing
and serving some interfaces or not.

interface Admin;
interface AdminConnection;
interface A
{
	.... definitions of  PropSeq and exception Reject

	void	connectAdmin   (in  Admin     admin_obj,
							in  PropSeq
admin_attr,
							out AdminConnection
srv_obj) raises(Reject);
	....
};

My implementations are derived from POA_A therefore I have to override the
pure virtual function "connectAdmin" even if I'm not intending to implement
administration -I will throw Reject as follows: 

virtual void	connectAdmin(/*in*/  Admin_ptr             admin_obj,
						 /*in*/  const PropSeq&
admin_attr,
						 /*out*/ AdminConnection_out
srv_obj)
{
	throw Reject(some_code, "Not implemented");
}



Unfortunately the linker complains about unresolved externals (methods)
NP_alignedSize
marshalObjRef
unmarshalObjRef
_nil(void)
release

for the both Admin_Helper and AdminConnection_Helper.

Of course I would prefer not to keep dummy declarations if possible.
Moreover I would like not to expose the IDL definitions of Admin and
AdminConnection for applications which will not implement these interfaces
and will keep rejecting on that call.

Any ideas?
Should I define empty interfaces and derive the real ones from them?
Sound this like a right way to do it?

Any help would be appreciated.
Roumen