Posted By:
Fritz_M
Posted On:
Friday, January 15, 2010 02:26 AM
Hi! I have a problem using JacORB with complex return types and I can't solve it. I thought this is a simple question for CORBA users, but at several other forums the members could not help me :cry:. I´m shure there are a lot of programmers that do exactly what I want each day, because this is just a normal usage of CORBA. My IDL Definition is (shorted): interface Session; interface Bank { Session GetSession(); void DropSession(in Session theSession); }; interface Session { Account GetAccount(in long accountID, in string pin); }; I´ve implemented both classes using the tie approach, my Java code lo
More>>
Hi!
I have a problem using JacORB with complex return types and I can't solve it. I thought this is a simple question for CORBA users, but at several other forums the members could not help me :cry:. I´m shure there are a lot of programmers that do exactly what I want each day, because this is just a normal usage of CORBA.
My IDL Definition is (shorted):
interface Session;
interface Bank
{
Session GetSession();
void DropSession(in Session theSession);
};
interface Session
{
Account GetAccount(in long accountID, in string pin);
};
I´ve implemented both classes using the tie approach, my Java code looks like this:
public class BankOpImpl implements BankOperations
{ ...
public Session GetSession()
{
...
}
...
}
Now I really don´t know, how I can return an object that implements the interface Session (JacORB created for both classes "Bank" and "Session" die Java classes/interfaces "*", "*Helper", "*Holder", "*Operations", "*POA", "*POATie").
I just can't return something like
return new SessionPOATie(new SessionOpImpl());
because SessionPOATie does not implement the interface Session. Even more, no generated class does this! So I do not know how to return just an object that implements Session. (The "father" object "Bank" I can look up well using a nameservice (exactly like described in the Tut), but I don't want to give each member of the father object a separate name, of course.
Can anybody help me?
Thank you very much for your help :rolling: ,
Casiopaya
<<Less