[Basic]Initialisation of a web service

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

[Basic]Initialisation of a web service

Philippe Denis
Hello everybody,

I'm trying to use a web service with OOo Basic. However when I try to  
initialize this web service, I receive one error.

Basicly, I test with this code :
Sub Main
    proxyFac =  
createUNOService("com.sun.star.webservices.proxy.ProxyFactory")

    'Getting the UNO service
    proxyFac =  
createUNOService("com.sun.star.webservices.proxy.ProxyFactory")

    ' Initializing of the ProxyFactory by providing the WSDL:
    proxyFac.initialize(Array("http://www.flash-db.com/services/ws/companyInfo.wsdl 
"))
End Sub

The line 'proxyFac.initialize(...)' returns an error. I'v taken a  
picture of this error : http://user.services.openoffice.org/fr/forum/download/file.php?id=12779&mode=view

However, with this WSDL (http://www.rightactionscript.com/states/webservice/StatesService.php?wsdl 
), the initialisation works.

To install the web service and the JWSDP, I followed this tutorial : http://udk.openoffice.org/java/examples/wsproxy/component_description.html#ToCDownload 
   and I'm sure it works.

I dont't understand why It doesn't work in few case. Maybe, the error  
is provide by the WSDL File Itself.

I would be glad if you can solve my problem,

Thank you very much,


Philippe


PS : you can see my topic here : http://user.services.openoffice.org/fr/forum/viewtopic.php?f=8&t=20672&p=112242#p112242
                                                            http://www.oooforum.org/forum/viewtopic.phtml?t=94849
Reply | Threaded
Open this post in threaded view
|

Re: [Basic]Initialisation of a web service

stephan.bergmann
On 01/27/10 10:20, Philippe Denis wrote:

> I'm trying to use a web service with OOo Basic. However when I try to
> initialize this web service, I receive one error.
>
> Basicly, I test with this code :
> Sub Main
>    proxyFac =
> createUNOService("com.sun.star.webservices.proxy.ProxyFactory")
>
>    'Getting the UNO service
>    proxyFac =
> createUNOService("com.sun.star.webservices.proxy.ProxyFactory")
>
>    ' Initializing of the ProxyFactory by providing the WSDL:
>    
> proxyFac.initialize(Array("http://www.flash-db.com/services/ws/companyInfo.wsdl"))
>
> End Sub
>
> The line 'proxyFac.initialize(...)' returns an error. I'v taken a
> picture of this error :
> http://user.services.openoffice.org/fr/forum/download/file.php?id=12779&mode=view 
>
>
> However, with this WSDL
> (http://www.rightactionscript.com/states/webservice/StatesService.php?wsdl),
> the initialisation works.
>
> To install the web service and the JWSDP, I followed this tutorial :
> http://udk.openoffice.org/java/examples/wsproxy/component_description.html#ToCDownload 
> and I'm sure it works.
>
> I dont't understand why It doesn't work in few case. Maybe, the error is
> provide by the WSDL File Itself.

Looks like the code at
<http://udk.openoffice.org/source/browse/udk/soap/proxy/src/com/sun/star/comp/webservice/unoproxy/WSDLDocumentHandler.java?rev=1.12&view=markup>
cannot cope with certain kind of input (definitionsMap is set at l. 124
for a startElement with qName=="definitions" and is used---and obviously
still null in your case---at l. 244 for a startElement with
sName==MESSAGE; maybe the sequence of startElements in your case is not
as anticipated by the author of the code).  That code lies unmaintained
for a very long time now.  I guess you are on your own debugging it...

-Stephan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [Basic]Initialisation of a web service

Philippe Denis
After some researchs, I think my code doesn't accept the WSDL 2. I  
explain : the WSDL working are from the version 1 of WSDL and the  
others that don't wrok are from the version 2.

If I understand, this problem is from the UDK projet or no?

Thanks

Le 27-janv.-10 à 11:04, Stephan Bergmann a écrit :

> On 01/27/10 10:20, Philippe Denis wrote:
>> I'm trying to use a web service with OOo Basic. However when I try  
>> to initialize this web service, I receive one error.
>> Basicly, I test with this code :
>> Sub Main
>>   proxyFac =  
>> createUNOService("com.sun.star.webservices.proxy.ProxyFactory")
>>   'Getting the UNO service
>>   proxyFac =  
>> createUNOService("com.sun.star.webservices.proxy.ProxyFactory")
>>   ' Initializing of the ProxyFactory by providing the WSDL:
>>   proxyFac.initialize(Array("http://www.flash-db.com/services/ws/companyInfo.wsdl 
>> ")) End Sub
>> The line 'proxyFac.initialize(...)' returns an error. I'v taken a  
>> picture of this error : http://user.services.openoffice.org/fr/forum/download/file.php?id=12779&mode=view 
>>  However, with this WSDL (http://www.rightactionscript.com/states/webservice/StatesService.php?wsdl 
>> ), the initialisation works.
>> To install the web service and the JWSDP, I followed this  
>> tutorial : http://udk.openoffice.org/java/examples/wsproxy/component_description.html#ToCDownload 
>>   and I'm sure it works.
>> I dont't understand why It doesn't work in few case. Maybe, the  
>> error is provide by the WSDL File Itself.
>
> Looks like the code at <http://udk.openoffice.org/source/browse/udk/soap/proxy/src/com/sun/star/comp/webservice/unoproxy/WSDLDocumentHandler.java?rev=1.12&view=markup 
> > cannot cope with certain kind of input (definitionsMap is set at  
> l. 124 for a startElement with qName=="definitions" and is used---
> and obviously still null in your case---at l. 244 for a startElement  
> with sName==MESSAGE; maybe the sequence of startElements in your  
> case is not as anticipated by the author of the code).  That code  
> lies unmaintained for a very long time now.  I guess you are on your  
> own debugging it...
>
> -Stephan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [Basic]Initialisation of a web service

stephan.bergmann
On 01/27/10 11:11, Philippe Denis wrote:
> After some researchs, I think my code doesn't accept the WSDL 2. I
> explain : the WSDL working are from the version 1 of WSDL and the others
> that don't wrok are from the version 2.
>
> If I understand, this problem is from the UDK projet or no?

The code is archived in the (old CVS) repository of the UDK project,
right.  But there is nobody (to my knowledge) who maintains that code.
(The code mainly came out of some internship project several years ago.)
  If you want to improve it---go ahead!  :)

-Stephan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [Basic]Initialisation of a web service

Philippe Denis
Hello,

Last question : if I want to modify the web service package. How can I  
do?
Actualy, I'm trying to modify the .jar that is inside of this file : http://udk.openoffice.org/java/examples/wsproxy/WebServiceProxy.zip
But after, It's impossible to install this package in OO.

Could you help me?

Thank you very much


PhD

Le 27-janv.-10 à 11:23, Stephan Bergmann a écrit :

> On 01/27/10 11:11, Philippe Denis wrote:
>> After some researchs, I think my code doesn't accept the WSDL 2. I  
>> explain : the WSDL working are from the version 1 of WSDL and the  
>> others that don't wrok are from the version 2.
>> If I understand, this problem is from the UDK projet or no?
>
> The code is archived in the (old CVS) repository of the UDK project,  
> right.  But there is nobody (to my knowledge) who maintains that  
> code. (The code mainly came out of some internship project several  
> years ago.)  If you want to improve it---go ahead!  :)
>
> -Stephan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [Basic]Initialisation of a web service

stephan.bergmann
On 01/28/10 11:31, Philippe Denis wrote:
> Last question : if I want to modify the web service package. How can I do?
> Actualy, I'm trying to modify the .jar that is inside of this file :
> http://udk.openoffice.org/java/examples/wsproxy/WebServiceProxy.zip
> But after, It's impossible to install this package in OO.

The source can only be accessed via CVS (it has not been migrated to HG,
unlike the still active parts of the old OOo CVS repository; also see
<http://wiki.services.openoffice.org/wiki/CVS>), module udk/soap.  I
never really looked at the code, but it looks like
udk/soap/proxy/build.xml is an ant file to build the stuff (requiring
that "Environment variables ODK_HOME and OFFICE_PROGRAM_PATH *must*
exist", so you would have to set at least those before trying it out; I
can imagine that there are further problems, as the structure of an OOo
installation set has changed significantly over the years).  If you get
stuck anywhere, feel free to ask.

-Stephan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]