RE: Simplifying code generated by adb

2008-09-15 Thread Raghu Udupa
Thanks Dimuthu. At this point, I am proceeding with Samisa's suggestion to 
modify generated code by hand. I will take a look at the new wsdl2c at a later 
time.
 
Regards,
Raghu



From: Dimuthu Gamage [mailto:[EMAIL PROTECTED]
Sent: Mon 9/15/2008 11:26 AM
To: Apache AXIS C User List
Subject: Re: Simplifying code generated by adb


Hi Raghu,
The adb generated code will completely depends on the schema you have. If you 
really want to generate a similar set of adb structs you need to have a similar 
set of schemas in your WSDL.

Or with the fix to the JIRA https://issues.apache.org/jira/browse/AXIS2C-1145 
you are no longer need to write wrapper structs. And it will really minimize 
the code you have to write. (explained more on my blog, 
http://www.dimuthu.org/blog/2008/09/15/use-axis2c-wsdl2c-with-unwrapped-mode-for-simpler-code/
 )

Thanks
Dimuthu


On Fri, Sep 12, 2008 at 11:24 PM, Raghu Udupa <[EMAIL PROTECTED]> wrote:


I am using codegen with adb option to generate code for client stub and 
service processing. I have many simple string types defined in the XML schema. 
There is a significant amount of repetitive code generated for various 
elements. Generated code works properly. 

 

Is there a way, I mean, suggested guidelines to simplify the code 
generated to make all similar elements to share same methods?

 

Thanks,

Raghu

 

 




-- 
Thanks,
Dimuthu Gamage

http://www.dimuthu.org  
http://www.wso2.org  

<>-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: Declaring a namespace of an XPath expression with Savan/C

2008-09-15 Thread Suguru HAMAZAKI
Hi,

Thanks for responding, Damitha.

On Mon, 15 Sep 2008 17:46:05 +0530, Damitha Kumarage <[EMAIL PROTECTED]> wrote
> Savan/C currently support XPath filtering. In order for server side to 
> support to support XPath filtering you need to build Savan/C module with 
> filtering enabled. Also make sure that you have libxml2 and libxslt dev 
> packages installed in your system.
> 
> To understand how this works run the default subscriber client sample 
> with filtering related code uncommented.(It is by default commented in 
> the sample).

I built Savan/C with filtering option enabled and tried the bundled
samples, subscriber on client side and publisher and listener on
server side, and they're working OK.

> Following is the Subscribe element it send
> 
> http://schemas.xmlsoap.org/ws/2004/08/eventing";>
>  
>  
> 
> http://localhost:9090/axis2/services/listener
>  
>   Dialect="http://www.w3.org/TR/1999/REC-xpath-19991116";>//[EMAIL 
> PROTECTED]'5']
>   

My point is Savan/C API lacks means to specify an XPath expression
with namespace qualified names, because there is no way to declare the
namespaces which is used in the expression. Note that, in the example
you showed above, the element name, test3, and the attribute name,
data, are both unqualified. Is it impossible to specify an expression
like

  //ns1:[EMAIL PROTECTED]:data='5']

and declare ns1 and ns2 in wse:Filter element?

Hamazy

-- 
HAMAZAKI, Suguru 
http://webspiritus.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Simplifying code generated by adb

2008-09-15 Thread Dimuthu Gamage
Hi Raghu,
The adb generated code will completely depends on the schema you have. If
you really want to generate a similar set of adb structs you need to have a
similar set of schemas in your WSDL.

Or with the fix to the JIRA
https://issues.apache.org/jira/browse/AXIS2C-1145 you are no longer need to
write wrapper structs. And it will really minimize the code you have to
write. (explained more on my blog,
http://www.dimuthu.org/blog/2008/09/15/use-axis2c-wsdl2c-with-unwrapped-mode-for-simpler-code/)

Thanks
Dimuthu

On Fri, Sep 12, 2008 at 11:24 PM, Raghu Udupa <[EMAIL PROTECTED]> wrote:

>  I am using codegen with adb option to generate code for client stub and
> service processing. I have many simple string types defined in the XML
> schema. There is a significant amount of repetitive code generated for
> various elements. Generated code works properly.
>
>
>
> Is there a way, I mean, suggested guidelines to simplify the code generated
> to make all similar elements to share same methods?
>
>
>
> Thanks,
>
> Raghu
>
>
>
>
>



-- 
Thanks,
Dimuthu Gamage

http://www.dimuthu.org
http://www.wso2.org


Re: Simplifying code generated by adb

2008-09-15 Thread Samisa Abeysinghe

Raghu Udupa wrote:


I am using codegen with adb option to generate code for client stub 
and service processing. I have many simple string types defined in the 
XML schema. There is a significant amount of repetitive code generated 
for various elements.




This is a problem in the design of the WSDL that you are using.


Generated code works properly.

 

Is there a way, I mean, suggested guidelines to simplify the code 
generated to make all similar elements to share same methods?




The code generation tool is not that smart. You can fix it manually though.

Samisa...

 


Thanks,

Raghu

 

 





No virus found in this incoming message.
Checked by AVG - http://www.avg.com 
Version: 8.0.169 / Virus Database: 270.6.21/1669 - Release Date: 9/12/2008 2:18 PM


  



--
Samisa Abeysinghe 
Director, Engineering; WSO2 Inc.


http://www.wso2.com/ - "The Open Source SOA Company"


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: thread safe axis2c api calls

2008-09-15 Thread Samisa Abeysinghe

Tammy Martin wrote:

Hello all,
 
Are the axis2c api calls thread safe?


What is your use case?

Samisa...

 
Thanks,

Tammy



No virus found in this incoming message.
Checked by AVG - http://www.avg.com 
Version: 8.0.169 / Virus Database: 270.6.21/1669 - Release Date: 9/12/2008 2:18 PM


  



--
Samisa Abeysinghe 
Director, Engineering; WSO2 Inc.


http://www.wso2.com/ - "The Open Source SOA Company"


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]