WSDL2JAVA options

2008-11-18 Thread ibrahim demir
Hi All;

I'm creating my classes with axis2 wsdl2java tool. But teh resultant classes 
are hard to read. It adds the class package name before every element. Is there 
any option to stop them. Or do you have any way to get rid of them quickly.

As an example:

private staticjava.lang.String generatePrefix(java.lang.String 
namespace) { 
   if(namespace.equals(urn:cs.com.tr/banking)){ 
   return ; 
   } 
   return 
org.apache.axis2.databinding.utils.BeanUtil.getUniquePrefix(); 
   } 


I do not want to see java.lang.String in front of generatePrefix method. 

Yours.

 Ibrahim DEMIR
CyberSoft Yazilim Muh.
http://www.ibrahimdemir.org


  

Re: WSDL2JAVA options

2008-11-18 Thread Amila Suriarachchi
this is the default method it generates the code. this has done to
avoid compilation errors. There is no option to change it.

thanks,
Amila.

On 11/18/08, ibrahim demir [EMAIL PROTECTED] wrote:
 Hi All;

 I'm creating my classes with axis2 wsdl2java tool. But teh resultant classes
 are hard to read. It adds the class package name before every element. Is
 there any option to stop them. Or do you have any way to get rid of them
 quickly.

 As an example:

 private staticjava.lang.String generatePrefix(java.lang.String
 namespace) {
if(namespace.equals(urn:cs.com.tr/banking)){
return ;
}
return
 org.apache.axis2.databinding.utils.BeanUtil.getUniquePrefix();
}


 I do not want to see java.lang.String in front of generatePrefix method.

 Yours.

  Ibrahim DEMIR
 CyberSoft Yazilim Muh.
 http://www.ibrahimdemir.org





-- 
Amila Suriarachchi
WSO2 Inc.
blog: http://amilachinthaka.blogspot.com/

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



Re: WSDL2JAVA options

2008-11-18 Thread Manuel Darveau
Hi,

You could import the generated classes to eclipse and format the whole code
using the format tool.
This can remove unneeded package prefix and do various formatting based on
your preferences.

Manuel

On Tue, Nov 18, 2008 at 8:18 AM, ibrahim demir [EMAIL PROTECTED]wrote:

 Hi All;

 I'm creating my classes with axis2 wsdl2java tool. But teh resultant
 classes are hard to read. It adds the class package name before every
 element. Is there any option to stop them. Or do you have any way to get rid
 of them quickly.

 As an example:

 private static java.lang.String generatePrefix(java.lang.String
 namespace) {
if(namespace.equals(urn:cs.com.tr/banking)){
return ;
}
return
 org.apache.axis2.databinding.utils.BeanUtil.getUniquePrefix();
}


 I do not want to see java.lang.String in front of generatePrefix method.

 Yours.

 Ibrahim DEMIR
 CyberSoft Yazilim Muh.
 http://www.ibrahimdemir.org








WSDL2JAVA options (-nv) ?

2008-06-26 Thread callagc4


Hi,

We have recently come across the following senario with our xsd schema:

File 1 has namespace A
File 2 has namespace B
File 3 has namespace A

File 1 imports File 2 imports File 3

This causes a validation exception.

When using the com.sun.tools.xjc.XJCFacade directly this senarion fails
generation.
When using the com.sun.tools.xjc.XJCFacade directly and specifying the -nv
option it generates successfully.

Question1: What is the equivalent parameter for -nv when using Axis2's
wsdl2java?

Question2: What is the significance of specifying the -nv option. I have
read the jaxb resource on the xjc at
http://java.sun.com/webservices/docs/2.0/jaxb/xjc.html which details the -nc
option but i would like to now just exactly how un-strict the validation
becomes.

Thanks,
Cathal
-- 
View this message in context: 
http://www.nabble.com/WSDL2JAVA-options-%28-nv%29---tp18130698p18130698.html
Sent from the Axis - User mailing list archive at Nabble.com.


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