Hi !
I've to following problem :
I'm building a connection between a
wrapper (built in PHP) -> mediator (in Java) -> wrapper (in PHP).
The Mediator only passes the values through from the first wrapper to the
second one and the other direction. The Mediator and one of the wrappers are
offering services for this. The remaining wrapper is only a client. He
accesses the Mediator, sends a request over Web Services and awaits an
answer. Mediator and Wrapper are offering the same services so I had to
build two sets of WSDL documents with only few variation (namespace,
service-address).
Mediator :
SearchServiceM2SOAPBindingImpl
SearchServiceMLocator
SearchServiceMInterface
SearchServiceMSkeleton
....
Wrapper : -> The service of the wrapper is implemented by
the wrapper elsewhere. These classes are
SearchServiceWLocator only all needed for passing the incoming
SearchServiceWStub requests directly the to Wrapper-Service
....
Well, I took these WSDL documents and used WSDL2Java (with Jbuilder9) to
generate the Impl. Interface and Skeleton Files for the Server-side
(Java-Mediator) as well as the Stubs for accessing the Wrapper-Service.
The remaining part should have been quite easy, because I know, I only had
to modify the Impl Classes, Jbuilder generated. There, I made objects out of
the Stubs for the Wrapper-Service and executed the same methods and
functions on it, that I was receiving from the outside (to my Skeletons)
(because the services of the Wrapper-Service and my Mediator were the same).
I passed the results directly back by the return-statement, so my Impl
finally had indeed only one line.
That didn't worked. I was wondering and reviewed the book, I bought to make
the Web-Service Programming in Java nice and easy. There I found the
solution :
I would have to instanciiate my Locator Class (from the Wrapper Service
files), execute "get<MyServiceName>" on it and cast it to the Stub. Well.
That sounded really easy. But it wasn't. I don't know, if my book is
outdated, but the Jbuilder-generated Locator-class
(which was directly received by the axis1.1 WSDL2Java statement, like
JBuilder told me after a check)
didn't owns a function, that passes me a service. Well, there is also none,
that resembles to such a function.
I don't know, how to get this simple throughpassing to work ... please help
me with the necessary piece of code :(
Thanx in advance !
Regards, Arne