[ 
https://issues.apache.org/jira/browse/AXIS2-3952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12634536#action_12634536
 ] 

Jan Moravec commented on AXIS2-3952:
------------------------------------

IMO not quite so. What if you do not want the 'src' directory at all? It would 
mean that you have to specify an empty string for the source dir. Not nice.

I believe it should be something along these lines:

File outputDir = new File(cgconfig.getOutputLocation());

if (cgconfig.getSourceLocation() != null) 
  outputDir = new File(outputDir, cgconfig.getSourceLocation());

outputDir.mkdir();

PS: I switched my project to Sun Metro stack and am very happy ever since :)

> Dubious src subdirectory (hard-coded!!!) created by wsdl2java with JAXBRI 
> binding
> ---------------------------------------------------------------------------------
>
>                 Key: AXIS2-3952
>                 URL: https://issues.apache.org/jira/browse/AXIS2-3952
>             Project: Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: codegen
>    Affects Versions: 1.4
>            Reporter: Jan Moravec
>
> Hello,
> After running the following wsdl2java command I end up with a dubious src 
> directory generated underneath the output directory that I specify on the 
> wsdl2java command line (-o option).
> ./wsdl2java.sh -s -o . -d jaxbri -S -noBuildXML -ns2p 
> http://www.webservicex.net=net.webservicex -uri ./geoipservice.wsdl
> This command generates the client stub underneath the current directory and 
> jaxb sources in src subdirectory. The expected behavior would be to have all 
> the sources generated in the specified (in my case current) directory in 
> their respective packages of course.
> The problem is apparently in the 
> org.apache.axis2.jaxbri.CodeGenerationUtility whose processSchemas method 
> executes:
> File outputDir = new File(cgconfig.getOutputLocation(), "src");
> outputDir.mkdir();
> I believe, it should be simplified to:
> cgconfig.getOutputLocation().mkdir();
> Thanks,
> Jan Moravec

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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

Reply via email to