axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aj...@apache.org
Subject svn commit: r449519 - in /webservices/axis2/trunk/java/modules: adb-codegen/src/org/apache/axis2/schema/ codegen/src/org/apache/axis2/wsdl/codegen/ codegen/src/org/apache/axis2/wsdl/codegen/emitter/ codegen/src/org/apache/axis2/wsdl/codegen/extension/ ...
Date Sun, 24 Sep 2006 22:50:14 GMT
Author: ajith
Date: Sun Sep 24 15:50:13 2006
New Revision: 449519

URL: http://svn.apache.org/viewvc?view=rev&rev=449519
Log:
Fixing blocker Axis2-663
1. Added the source and resource locations to the CodeGenConfiguration.java
2. Added these two properties to the codegen-config.properties file and the relevant property loaders so that they can pick up defaults from the property file
3. Changed the extensions and the emmiters to take the names of src and resource folder names from the configuration
4. Added two new parameters to the codegen options
5. Fixed a few documentation errors here and there 

A decent test case is missing which will come next

Modified:
    webservices/axis2/trunk/java/modules/adb-codegen/src/org/apache/axis2/schema/ExtensionUtility.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodeGenConfiguration.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodegenConfigLoader.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/codegen-config.properties
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/CEmitter.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/JaxMeExtension.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/PolicyEvaluator.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/TypeMapperExtension.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/adbAntBuildTemplate.xsl
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/defaultAntBuildTemplate.xsl
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxbriAntBuildTemplate.xsl
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxmeAntBuildTemplate.xsl
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jibxAntBuildTemplate.xsl
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/xmlbeansAntBuildTemplate.xsl
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOption.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOptionConstants.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/ConfigPropertyFileLoader.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/WSDL2JavaOptionsValidator.java
    webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/XSLTIncludeResolver.java
    webservices/axis2/trunk/java/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java

Modified: webservices/axis2/trunk/java/modules/adb-codegen/src/org/apache/axis2/schema/ExtensionUtility.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/adb-codegen/src/org/apache/axis2/schema/ExtensionUtility.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/adb-codegen/src/org/apache/axis2/schema/ExtensionUtility.java (original)
+++ webservices/axis2/trunk/java/modules/adb-codegen/src/org/apache/axis2/schema/ExtensionUtility.java Sun Sep 24 15:50:13 2006
@@ -351,11 +351,12 @@
      *
      * @param options
      */
-    private static void populateDefaultOptions(CompilerOptions options, CodeGenConfiguration configuration) {
+    private static void populateDefaultOptions(CompilerOptions options,
+                                               CodeGenConfiguration configuration) {
         //create the output directory
         File outputDir = configuration.isFlattenFiles() ?
                 configuration.getOutputLocation() :
-                new File(configuration.getOutputLocation(), "src");
+                new File(configuration.getOutputLocation(), configuration.getSourceLocation());
 
         if (!outputDir.exists()) {
             outputDir.mkdirs();

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodeGenConfiguration.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodeGenConfiguration.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodeGenConfiguration.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodeGenConfiguration.java Sun Sep 24 15:50:13 2006
@@ -87,6 +87,31 @@
         this.flattenFiles = flattenFiles;
     }
 
+    /**
+     * Folder name for the resource files
+     */
+    private  String resourceLocation = ConfigPropertyFileLoader.getResourceFolderName();
+
+    public String getResourceLocation() {
+        return resourceLocation;
+    }
+
+    public void setResourceLocation(String resourceLocation) {
+        this.resourceLocation = resourceLocation;
+    }
+
+    /**
+     * Folder name for the source files
+     */
+    private String sourceLocation  = ConfigPropertyFileLoader.getSrcFolderName();
+
+    public String getSourceLocation() {
+        return sourceLocation;
+    }
+
+    public void setSourceLocation(String sourceLocation) {
+        this.sourceLocation = sourceLocation;
+    }
 
     /**
      * Determines whether the parameters are wrapped or unwrapped

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodegenConfigLoader.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodegenConfigLoader.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodegenConfigLoader.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/CodegenConfigLoader.java Sun Sep 24 15:50:13 2006
@@ -74,7 +74,6 @@
         }
 
         commandLineOption = loadOption(WSDL2JavaConstants.STUB_LANGUAGE_OPTION, WSDL2JavaConstants.STUB_LANGUAGE_OPTION_LONG, optionMap);
-        //The language here
         if (commandLineOption != null) {
             config.setOutputLanguage(commandLineOption.getOptionValue());
         }
@@ -84,9 +83,24 @@
             config.setDatabindingType(commandLineOption.getOptionValue());
         }
 
+
         commandLineOption = loadOption(WSDL2JavaConstants.UNPACK_CLASSES_OPTION, WSDL2JavaConstants.UNPACK_CLASSES_OPTION_LONG, optionMap);
         if (commandLineOption != null) {
             config.setPackClasses(false);
+        }
+
+        // source folder
+        commandLineOption = loadOption(WSDL2JavaConstants.SOURCE_FOLDER_NAME_OPTION,
+                WSDL2JavaConstants.SOURCE_FOLDER_NAME_OPTION_LONG, optionMap);
+        if (commandLineOption != null) {
+            config.setSourceLocation(commandLineOption.getOptionValue());
+        }
+
+         // resource folder
+        commandLineOption = loadOption(WSDL2JavaConstants.RESOURCE_FOLDER_OPTION,
+                WSDL2JavaConstants.RESOURCE_FOLDER_OPTION_LONG, optionMap);
+        if (commandLineOption != null) {
+            config.setResourceLocation(commandLineOption.getOptionValue());
         }
 
         commandLineOption = loadOption(WSDL2JavaConstants.PORT_NAME_OPTION, WSDL2JavaConstants.PORT_NAME_OPTION_LONG, optionMap);

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/codegen-config.properties
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/codegen-config.properties?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/codegen-config.properties (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/codegen-config.properties Sun Sep 24 15:50:13 2006
@@ -66,6 +66,10 @@
 # Default language, this is the default language that would be picked when no language is specified. it should be
 # one of the languages specified above
 codegen.languages.default=java
+# Default source folder name
+codegen.general.src.name=src
+# Default resource folder name
+codegen.general.resource.name=resources
 #####################################################################################################################
 ########################  Language specific section #################################################################
 #####################################################################################################################

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/AxisServiceBasedMultiLanguageEmitter.java Sun Sep 24 15:50:13 2006
@@ -143,9 +143,7 @@
 
     protected Map instantiatableMessageClassNames = new HashMap();
 
-    protected static final String SRC_DIR_NAME = "src";
     protected static final String TEST_SRC_DIR_NAME = "test";
-    protected static final String RESOURCE_SRC_DIR_NAME = "resources";
 
 
     /**
@@ -187,7 +185,7 @@
     /**
      * Returns the fully qualified Stub name
      * reused in many methods
-     * @return
+     * @return classname
      */
     protected String getFullyQualifiedStubName() {
         String packageName = codeGenConfiguration.getPackageName();
@@ -246,7 +244,7 @@
     /**
      * Emits the stubcode with bindings.
      * @see org.apache.axis2.wsdl.codegen.emitter.Emitter#emitStub()
-     * @throws Exception
+     * @throws CodeGenerationException
      */
     public void emitStub() throws CodeGenerationException {
         try{
@@ -329,6 +327,8 @@
         addAttribute(doc, "package", dotSeparatedValues[0], rootElement);
         addAttribute(doc, "name", serviceName, rootElement);
         addAttribute(doc, "servicename", serviceName, rootElement);
+        addAttribute(doc, "src", codeGenConfiguration.getSourceLocation(), rootElement);
+        addAttribute(doc, "resource", codeGenConfiguration.getResourceLocation(), rootElement);
         if (codeGenConfiguration.isServerSide()) {
             addAttribute(doc,
                     "isserverside",
@@ -361,7 +361,7 @@
 
     /**
      * Creates the XML Model for the test case
-     * @return
+     * @return DOM document
      */
     protected Document createDOMDocumentForTestCase() {
         String coreClassName = makeJavaClassName(axisService.getName());
@@ -401,7 +401,7 @@
                 new InterfaceImplementationWriter(
                         codeGenConfiguration.isFlattenFiles() ?
                                 getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                                getOutputDirectory(codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME),
+                                getOutputDirectory(codeGenConfiguration.getOutputLocation(), codeGenConfiguration.getSourceLocation()),
                         codeGenConfiguration.getOutputLanguage());
 
         writeClass(interfaceImplModel, writer);
@@ -487,7 +487,7 @@
      * A util method that returns a unique list of faults
      *
      * @param doc
-     * @return
+     * @return DOM element
      */
     protected Element getUniqueListofFaults(Document doc) {
         Element rootElement = doc.createElement("fault-list");
@@ -595,7 +595,8 @@
                     new CallbackHandlerWriter(
                             codeGenConfiguration.isFlattenFiles() ?
                                     getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                                    getOutputDirectory(codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME),
+                                    getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                                            codeGenConfiguration.getSourceLocation()),
                             codeGenConfiguration.getOutputLanguage());
 
             writeClass(interfaceModel, callbackWriter);
@@ -631,7 +632,8 @@
                 new InterfaceWriter(
                         codeGenConfiguration.isFlattenFiles() ?
                                 getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                                getOutputDirectory(codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME),
+                                getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                                        codeGenConfiguration.getSourceLocation()),
                         this.codeGenConfiguration.getOutputLanguage());
 
         writeClass(interfaceModel, interfaceWriter);
@@ -711,7 +713,7 @@
     }
     /**
      * Emits the skeleton
-     * @throws Exception
+     * @throws CodeGenerationException
      */
     public void emitSkeleton() throws CodeGenerationException {
 
@@ -791,7 +793,8 @@
         SchemaWriter schemaWriter = new SchemaWriter(
                 codeGenConfiguration.isFlattenFiles() ?
                         getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                        getOutputDirectory(codeGenConfiguration.getOutputLocation(), RESOURCE_SRC_DIR_NAME));
+                        getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                                codeGenConfiguration.getResourceLocation()));
 
 
         Map schemaMappings = axisService.getSchemaMappingTable();
@@ -811,7 +814,8 @@
             WSDL20Writer wsdl20Writer = new WSDL20Writer(
                     codeGenConfiguration.isFlattenFiles() ?
                             getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                            getOutputDirectory(codeGenConfiguration.getOutputLocation(), RESOURCE_SRC_DIR_NAME)
+                            getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                                    codeGenConfiguration.getResourceLocation())
             );
             wsdl20Writer.writeWSDL(axisService);
         } else {
@@ -819,7 +823,8 @@
             WSDL11Writer wsdl11Writer = new WSDL11Writer(
                     codeGenConfiguration.isFlattenFiles() ?
                             getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                            getOutputDirectory(codeGenConfiguration.getOutputLocation(), RESOURCE_SRC_DIR_NAME));
+                            getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                                    codeGenConfiguration.getResourceLocation()));
             wsdl11Writer.writeWSDL(axisService);
 
         }
@@ -903,7 +908,8 @@
                             new MessageReceiverWriter(
                                     codeGenConfiguration.isFlattenFiles() ?
                                             getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                                            getOutputDirectory(codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME),
+                                            getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                                                    codeGenConfiguration.getSourceLocation()),
                                     codeGenConfiguration.getOutputLanguage());
 
                     writeClass(classModel, writer);
@@ -916,7 +922,7 @@
      * Creates the XML model for the message receiver
      * @param mep
      * @param isServerSideInterface
-     * @return
+     * @return DOM Document
      */
     protected Document createDocumentForMessageReceiver(String mep, boolean isServerSideInterface) {
 
@@ -1238,7 +1244,8 @@
                     new ServiceXMLWriter(
                             codeGenConfiguration.isFlattenFiles() ?
                                     getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                                    getOutputDirectory(codeGenConfiguration.getOutputLocation(), RESOURCE_SRC_DIR_NAME),
+                                    getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                                            codeGenConfiguration.getResourceLocation()),
                             this.codeGenConfiguration.getOutputLanguage());
 
             writeClass(serviceXMLModel, serviceXmlWriter);
@@ -1262,9 +1269,9 @@
      * @param serviceName
      * @param className
      * @param doc
-     * @return
+     * @return DOM Element
      */
-    protected Node getServiceElement(String serviceName, String className, Document doc) {
+    protected Element getServiceElement(String serviceName, String className, Document doc) {
         Element rootElement = doc.createElement("interface");
 
         addAttribute(doc, "package", "", rootElement);
@@ -1297,7 +1304,8 @@
         ClassWriter skeletonWriter = new SkeletonWriter(
                 codeGenConfiguration.isFlattenFiles() ?
                         getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                        getOutputDirectory(codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME)
+                        getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                                codeGenConfiguration.getSourceLocation())
                 , this.codeGenConfiguration.getOutputLanguage());
 
         writeClass(skeletonModel, skeletonWriter);
@@ -1313,7 +1321,8 @@
         ClassWriter skeletonInterfaceWriter = new SkeletonInterfaceWriter(
                 codeGenConfiguration.isFlattenFiles() ?
                         getOutputDirectory(codeGenConfiguration.getOutputLocation(), null) :
-                        getOutputDirectory(codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME)
+                        getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                                codeGenConfiguration.getSourceLocation())
                 , this.codeGenConfiguration.getOutputLanguage());
 
         writeClass(skeletonModel, skeletonInterfaceWriter);
@@ -1322,7 +1331,7 @@
     /**
      * Creates the XMLModel for the skeleton
      * @param isSkeletonInterface
-     * @return
+     * @return DOM Document
      */
     protected Document createDOMDocumentForSkeleton(boolean isSkeletonInterface) {
         Document doc = getEmptyDocument();
@@ -1350,7 +1359,7 @@
 
     /**
      * Creates the XML model for the skeleton interface
-     * @return
+     * @return DOM Document
      */
     protected Document createDOMDocumentForSkeletonInterface() {
         Document doc = getEmptyDocument();
@@ -1378,7 +1387,7 @@
      * @param doc
      * @param rootElement
      * @param mep
-     * @return
+     * @return boolean
      */
     protected boolean loadOperations(Document doc, Element rootElement, String mep) {
         Element methodElement;
@@ -1677,7 +1686,7 @@
      * @param doc
      * @param operation
      * @param headerParameterQNameList
-     * @return
+     * @return DOM element
      */
     protected Element getInputElement(Document doc, AxisOperation operation, List headerParameterQNameList) {
         Element inputElt = doc.createElement("input");
@@ -1886,8 +1895,7 @@
      * @param doc
      * @param paramName
      * @param paramType
-     * @param
-     * @return
+     * @return DOM Element
      */
     protected Element generateParamComponent(Document doc,
                                              String paramName,
@@ -1903,7 +1911,7 @@
      * @param doc
      * @param paramName
      * @param paramType
-     * @return
+     * @return DOM Element
      */
     protected Element generateParamComponent(Document doc,
                                              String paramName,
@@ -1916,7 +1924,6 @@
      * element
      *
      * @param doc
-     * @param paramElement
      * @param paramName
      * @param paramType
      * @param opName

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/CEmitter.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/CEmitter.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/CEmitter.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/emitter/CEmitter.java Sun Sep 24 15:50:13 2006
@@ -99,14 +99,16 @@
         Document interfaceImplModel = createDOMDocumentForInterfaceImplementation();
 
         CStubHeaderWriter writerHStub =
-                new CStubHeaderWriter(getOutputDirectory(codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME),
+                new CStubHeaderWriter(getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                        codeGenConfiguration.getSourceLocation()),
                         codeGenConfiguration.getOutputLanguage());
 
         writeClass(interfaceImplModel, writerHStub);
 
 
         CStubSourceWriter writerCStub =
-                new CStubSourceWriter(getOutputDirectory(codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME),
+                new CStubSourceWriter(getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                        codeGenConfiguration.getSourceLocation()),
                         codeGenConfiguration.getOutputLanguage());
 
         writeClass(interfaceImplModel, writerCStub);
@@ -125,12 +127,12 @@
 
 
         CSkelHeaderWriter skeletonWriter = new CSkelHeaderWriter(getOutputDirectory(this.codeGenConfiguration.getOutputLocation(),
-                SRC_DIR_NAME), this.codeGenConfiguration.getOutputLanguage());
+                codeGenConfiguration.getSourceLocation()), this.codeGenConfiguration.getOutputLanguage());
 
         writeClass(skeletonModel, skeletonWriter);
 
         CSkelSourceWriter skeletonWriterStub = new CSkelSourceWriter(getOutputDirectory(this.codeGenConfiguration.getOutputLocation(),
-                SRC_DIR_NAME), this.codeGenConfiguration.getOutputLanguage());
+                codeGenConfiguration.getSourceLocation()), this.codeGenConfiguration.getOutputLanguage());
 
         writeClass(skeletonModel, skeletonWriterStub);
     }
@@ -141,7 +143,8 @@
     protected void writeCServiceSkeleton() throws Exception {
 
         Document skeletonModel = createDOMDocumentForServiceSkeletonXML();
-        CSvcSkeletonWriter writer = new CSvcSkeletonWriter(getOutputDirectory(codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME),
+        CSvcSkeletonWriter writer = new CSvcSkeletonWriter(getOutputDirectory(codeGenConfiguration.getOutputLocation(),
+                codeGenConfiguration.getSourceLocation()),
                                     codeGenConfiguration.getOutputLanguage());
 
         writeClass(skeletonModel, writer);
@@ -159,7 +162,8 @@
             // Write the service xml in a folder with the
             Document serviceXMLModel = createDOMDocumentForServiceXML();
             ClassWriter serviceXmlWriter =
-                    new CServiceXMLWriter(getOutputDirectory(this.codeGenConfiguration.getOutputLocation(), SRC_DIR_NAME),
+                    new CServiceXMLWriter(getOutputDirectory(this.codeGenConfiguration.getOutputLocation(),
+                            codeGenConfiguration.getResourceLocation()),
                             this.codeGenConfiguration.getOutputLanguage());
 
             writeClass(serviceXMLModel, serviceXmlWriter);

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/JaxMeExtension.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/JaxMeExtension.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/JaxMeExtension.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/JaxMeExtension.java Sun Sep 24 15:50:13 2006
@@ -103,7 +103,7 @@
 //                xmlObjectsVector.add(new InputSource(new StringReader(s)));
 //            }
 
-            File outputDir = new File(configuration.getOutputLocation(), "src");
+            File outputDir = new File(configuration.getOutputLocation(),configuration.getSourceLocation());
 
             JAXBSchemaReader reader = new JAXBSchemaReader();
             reader.setSupportingExtensions(true);

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/PolicyEvaluator.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/PolicyEvaluator.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/PolicyEvaluator.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/PolicyEvaluator.java Sun Sep 24 15:50:13 2006
@@ -50,7 +50,7 @@
 public class PolicyEvaluator implements CodeGenExtension {
 
     /**
-     * Inot method to initialization
+     * Init method to initialization
      * @param configuration
      * @param namespace2ExtsMap
      */

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/TypeMapperExtension.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/TypeMapperExtension.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/TypeMapperExtension.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/codegen/extension/TypeMapperExtension.java Sun Sep 24 15:50:13 2006
@@ -145,7 +145,7 @@
      * Gets the string content from an element. returns null if there are
      * no test nodes found
      * @param elt
-     * @return
+     * @return text cotent of the element
      */
     private String getTextFromElement(Element elt){
         NodeList children = elt.getChildNodes();

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/adbAntBuildTemplate.xsl
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/adbAntBuildTemplate.xsl?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/adbAntBuildTemplate.xsl (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/adbAntBuildTemplate.xsl Sun Sep 24 15:50:13 2006
@@ -1,9 +1,9 @@
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
     <xsl:output method="xml" indent="yes" omit-xml-declaration="yes"/>
     <xsl:template match="/ant">
-        <xsl:variable name="package">
-            <xsl:value-of select="@package"/>
-        </xsl:variable>
+        <xsl:variable name="package" select="@package"/>
+        <xsl:variable name="src" select="@src"/>
+        <xsl:variable name="resource" select="@resource"/>
 
         <project basedir=".">
             <xsl:choose>
@@ -30,7 +30,7 @@
                 <xsl:attribute name="value"><xsl:value-of select="@servicename"/></xsl:attribute>
             </property>
             <property name="src">
-                <xsl:attribute name="value">${project.base.dir}/src</xsl:attribute>
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$src"/></xsl:attribute>
             </property>
             <property name="test">
                 <xsl:attribute name="value">${project.base.dir}/test</xsl:attribute>
@@ -45,7 +45,7 @@
                 <xsl:attribute name="value">${build}/lib</xsl:attribute>
             </property>
             <property name="resources">
-                <xsl:attribute name="value">${project.base.dir}/resources</xsl:attribute>
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$resource"/></xsl:attribute>
             </property>
 
             <property name="jars.ok" value=""></property>

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/defaultAntBuildTemplate.xsl
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/defaultAntBuildTemplate.xsl?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/defaultAntBuildTemplate.xsl (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/defaultAntBuildTemplate.xsl Sun Sep 24 15:50:13 2006
@@ -1,7 +1,9 @@
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
     <xsl:output method="xml" indent="yes" omit-xml-declaration="yes"/>
     <xsl:template match="/ant">
-        <xsl:variable name="package"><xsl:value-of select="@package"/></xsl:variable>
+        <xsl:variable name="package" select="@package"/>
+        <xsl:variable name="src" select="@src"/>
+        <xsl:variable name="resource" select="@resource"/>
 
         <project basedir=".">
              <xsl:choose>
@@ -18,7 +20,7 @@
                 <xsl:attribute name="value">.</xsl:attribute>
             </property>
             <property name="src">
-                <xsl:attribute name="value">${project.base.dir}/src</xsl:attribute>
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$src"/></xsl:attribute>
             </property>
             <property name="test">
                 <xsl:attribute name="value">${project.base.dir}/test</xsl:attribute>
@@ -32,8 +34,8 @@
             <property name="lib">
                 <xsl:attribute name="value">${build}/lib</xsl:attribute>
             </property>
-            <property name="resources">
-                <xsl:attribute name="value">${project.base.dir}/resources</xsl:attribute>
+             <property name="resources">
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$resource"/></xsl:attribute>
             </property>
             <property name="name">
                 <xsl:attribute name="value"><xsl:value-of select="@servicename"/></xsl:attribute>

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxbriAntBuildTemplate.xsl
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxbriAntBuildTemplate.xsl?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxbriAntBuildTemplate.xsl (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxbriAntBuildTemplate.xsl Sun Sep 24 15:50:13 2006
@@ -1,7 +1,9 @@
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
     <xsl:output method="xml" indent="yes" omit-xml-declaration="yes"/>
     <xsl:template match="/ant">
-        <xsl:variable name="package"><xsl:value-of select="@package"/></xsl:variable>
+        <xsl:variable name="package" select="@package"/>
+        <xsl:variable name="src" select="@src"/>
+        <xsl:variable name="resource" select="@resource"/>
 
         <project basedir=".">
              <xsl:choose>
@@ -26,8 +28,8 @@
             <property name="name">
                 <xsl:attribute name="value"><xsl:value-of select="@servicename"/></xsl:attribute>
             </property>
-            <property name="src">
-                <xsl:attribute name="value">${project.base.dir}/src</xsl:attribute>
+             <property name="src">
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$src"/></xsl:attribute>
             </property>
             <property name="test">
                 <xsl:attribute name="value">${project.base.dir}/test</xsl:attribute>
@@ -42,7 +44,7 @@
                 <xsl:attribute name="value">${build}/lib</xsl:attribute>
             </property>
             <property name="resources">
-                <xsl:attribute name="value">${project.base.dir}/resources</xsl:attribute>
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$resource"/></xsl:attribute>
             </property>
 
             <property name="xbeans.packaged.jar.name" value="XBeans-packaged.jar"></property>

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxmeAntBuildTemplate.xsl
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxmeAntBuildTemplate.xsl?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxmeAntBuildTemplate.xsl (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jaxmeAntBuildTemplate.xsl Sun Sep 24 15:50:13 2006
@@ -1,7 +1,9 @@
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
     <xsl:output method="xml" indent="yes" omit-xml-declaration="yes"/>
     <xsl:template match="/ant">
-        <xsl:variable name="package"><xsl:value-of select="@package"/></xsl:variable>
+        <xsl:variable name="package" select="@package"/>
+        <xsl:variable name="src" select="@src"/>
+        <xsl:variable name="resource" select="@resource"/>
 
         <project basedir=".">
              <xsl:choose>
@@ -18,20 +20,23 @@
             <property name="axis2.home">
                 <xsl:attribute name="value">${env.AXIS2_HOME}</xsl:attribute>
             </property>
+            <property name="project.base.dir">
+                <xsl:attribute name="value">.</xsl:attribute>
+            </property>
             <property name="maven.class.path">
                 <xsl:attribute name="value"></xsl:attribute>
             </property>
             <property name="name">
                 <xsl:attribute name="value"><xsl:value-of select="@servicename"/></xsl:attribute>
             </property>
-            <property name="src">
-                <xsl:attribute name="value">${basedir}/src</xsl:attribute>
+             <property name="src">
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$src"/></xsl:attribute>
             </property>
             <property name="test">
-                <xsl:attribute name="value">${basedir}/test</xsl:attribute>
+                <xsl:attribute name="value">${project.base.dir}/test</xsl:attribute>
             </property>
             <property name="build">
-                <xsl:attribute name="value">${basedir}/build</xsl:attribute>
+                <xsl:attribute name="value">${project.base.dir}/build</xsl:attribute>
             </property>
             <property name="classes">
                 <xsl:attribute name="value">${build}/classes</xsl:attribute>
@@ -39,10 +44,9 @@
             <property name="lib">
                 <xsl:attribute name="value">${build}/lib</xsl:attribute>
             </property>
-            <property name="resources">
-                <xsl:attribute name="value">${basedir}/resources</xsl:attribute>
+           <property name="resources">
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$resource"/></xsl:attribute>
             </property>
-
             <property name="xbeans.packaged.jar.name" value="XBeans-packaged.jar"></property>
 
             <property name="jars.ok" value=""></property>

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jibxAntBuildTemplate.xsl
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jibxAntBuildTemplate.xsl?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jibxAntBuildTemplate.xsl (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/jibxAntBuildTemplate.xsl Sun Sep 24 15:50:13 2006
@@ -1,9 +1,9 @@
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
     <xsl:output method="xml" indent="yes" omit-xml-declaration="yes"/>
     <xsl:template match="/ant">
-        <xsl:variable name="package">
-            <xsl:value-of select="@package"/>
-        </xsl:variable>
+        <xsl:variable name="package" select="@package"/>
+        <xsl:variable name="src" select="@src"/>
+        <xsl:variable name="resource" select="@resource"/>
 
         <project basedir=".">
              <xsl:choose>
@@ -30,7 +30,7 @@
                 <xsl:attribute name="value"><xsl:value-of select="@servicename"/></xsl:attribute>
             </property>
             <property name="src">
-                <xsl:attribute name="value">${project.base.dir}/src</xsl:attribute>
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$src"/></xsl:attribute>
             </property>
             <property name="test">
                 <xsl:attribute name="value">${project.base.dir}/test</xsl:attribute>
@@ -45,7 +45,7 @@
                 <xsl:attribute name="value">${build}/lib</xsl:attribute>
             </property>
             <property name="resources">
-                <xsl:attribute name="value">${project.base.dir}/resources</xsl:attribute>
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$resource"/></xsl:attribute>
             </property>
 
             <property name="jars.ok" value=""></property>

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/xmlbeansAntBuildTemplate.xsl
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/xmlbeansAntBuildTemplate.xsl?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/xmlbeansAntBuildTemplate.xsl (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/template/general/xmlbeansAntBuildTemplate.xsl Sun Sep 24 15:50:13 2006
@@ -1,7 +1,10 @@
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
     <xsl:output method="xml" indent="yes" omit-xml-declaration="yes"/>
     <xsl:template match="/ant">
-        <xsl:variable name="package"><xsl:value-of select="@package"/></xsl:variable>
+
+        <xsl:variable name="package" select="@package"/>
+        <xsl:variable name="src" select="@src"/>
+        <xsl:variable name="resource" select="@resource"/>
 
         <project basedir=".">
              <xsl:choose>
@@ -27,8 +30,8 @@
             <property name="name">
                 <xsl:attribute name="value"><xsl:value-of select="@servicename"/></xsl:attribute>
             </property>
-            <property name="src">
-                <xsl:attribute name="value">${project.base.dir}/src</xsl:attribute>
+          <property name="src">
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$src"/></xsl:attribute>
             </property>
             <property name="test">
                 <xsl:attribute name="value">${project.base.dir}/test</xsl:attribute>
@@ -42,8 +45,8 @@
             <property name="lib">
                 <xsl:attribute name="value">${build}/lib</xsl:attribute>
             </property>
-            <property name="resources">
-                <xsl:attribute name="value">${project.base.dir}/resources</xsl:attribute>
+         <property name="resources">
+                <xsl:attribute name="value">${project.base.dir}/<xsl:value-of select="$resource"/></xsl:attribute>
             </property>
 
             <property name="xbeans.packaged.jar.name" value="XBeans-packaged.jar"></property>

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOption.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOption.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOption.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOption.java Sun Sep 24 15:50:13 2006
@@ -37,11 +37,8 @@
         if (type.startsWith("--")) type = type.replaceFirst("--", "");
         if (type.startsWith("-")) type = type.replaceFirst("-", "");
 
-        //for options that start with the extra prefix, don't do any change for the
-        //case
-        if (!type.startsWith(WSDL2JavaConstants.EXTRA_OPTIONTYPE_PREFIX)){
-            type = type.toLowerCase();
-        }
+        //we do not change the case of the option!
+
         this.type = type;
     }
 

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOptionConstants.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOptionConstants.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOptionConstants.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/CommandLineOptionConstants.java Sun Sep 24 15:50:13 2006
@@ -43,8 +43,10 @@
         String FLATTEN_FILES_OPTION = "f";
         String UNWRAP_PARAMETERS = "uw";
         String BACKWORD_COMPATIBILITY_OPTION = "b";
+        String SOURCE_FOLDER_NAME_OPTION = "S";
+        String RESOURCE_FOLDER_OPTION = "R";
+
 
-        
         //long option constants
         String OUTPUT_LOCATION_OPTION_LONG = "output";
         String SERVER_SIDE_CODE_OPTION_LONG = "server-side";
@@ -69,6 +71,8 @@
         String FLATTEN_FILES_OPTION_LONG = "flatten-filess";
         String UNWRAP_PARAMETERS_LONG = "unwrap-params";
         String BACKWORD_COMPATIBILITY_OPTION_LONG = "backword-compatible";
+        String SOURCE_FOLDER_NAME_OPTION_LONG = "source-folder";
+        String RESOURCE_FOLDER_OPTION_LONG = "resource-folder";
 
         String WSDL_VERSION_2 = "2.0";
         String WSDL_VERSION_2_OPTIONAL = "2";

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/ConfigPropertyFileLoader.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/ConfigPropertyFileLoader.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/ConfigPropertyFileLoader.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/ConfigPropertyFileLoader.java Sun Sep 24 15:50:13 2006
@@ -40,6 +40,8 @@
 
     private static Map dbSupporterTemplateNameMap;
     private static String testObjectTemplateName;
+    private static String srcFolderName;
+    private static String resourceFolderName;
     private static String[] extensionClassNames;
     private static String[] postExtensionClassNames;
     private static String[] thirdPartySchemaNames;
@@ -70,6 +72,8 @@
     private static final String DATA_BINDING_TEMPLATE_NAME_KEY_PREFIX = "codegen.databinding.";
     private static final String DATA_BINDING_TEMPLATE_NAME_KEY_SUFFIX = "template";
     private static final String DATA_BINDING_TEST_OBJECT_TEMPLATE_NAME_KEY = "codegen.databinding.testobject.template";
+    private static final String SOURCE_FOLDER_NAME_KEY = "codegen.general.src.name";
+    private static final String RESOURCE_FOLDER_NAME_KEY = "codegen.general.resource.name";
 
 
     public static final String DEFAULT_CODEGEN_CONFIG_PROPERTIES =
@@ -114,6 +118,8 @@
         databindingFrameworkNameToExtensionMap = null;
         defaultLanguage = null;
         defaultDBFrameworkName = null;
+        srcFolderName = null;
+        resourceFolderName = null;
 
     }
     private static void loadAllProperties() {
@@ -166,13 +172,25 @@
             if (tempString != null) {
                 unwrapSuppoerteddatabindingFrameworkNames = tempString.split(SEPARATOR_CHAR);
             }
-
+            
             //load the unwrap supported data binding framework names
             tempString = props.getProperty(DATA_BINDING_UNWRAP_DIRECT_FRAMEWORK_NAME_KEY);
             if (tempString != null) {
                 unwrapDirectdatabindingFrameworkNames = tempString.split(SEPARATOR_CHAR);
             }
 
+            //load the source folder
+            tempString = props.getProperty(SOURCE_FOLDER_NAME_KEY);
+            if (tempString != null) {
+                srcFolderName = tempString;
+            }
+
+            //load the resource folder name
+            tempString = props.getProperty(RESOURCE_FOLDER_NAME_KEY);
+            if (tempString != null) {
+                resourceFolderName = tempString;
+            }
+
             //populate the data binding framework name to extension name map
             tempString = props.getProperty(DATA_BINDING_FRAMEWORK_EXTENSION_NAME_KEY);
             if (tempString != null) {
@@ -276,6 +294,23 @@
     }
 
     /**
+     *
+     * @return the source folder name
+     */
+    public static String getResourceFolderName() {
+        return resourceFolderName;
+    }
+
+
+    /**
+     *
+     * @return the resource folder name
+     */
+    public static String getSrcFolderName() {
+        return srcFolderName;
+    }
+
+    /**
      * Gets the test object support template. This is used in the
      * generated test class.
      * @return Returns String.
@@ -336,7 +371,7 @@
 
     /**
      * Get the list of unwrap supported data binding frameworks
-     * @return
+     * @return list
      */
     public static List getUnwrapSupportedFrameworkNames(){
         return Arrays.asList(unwrapSuppoerteddatabindingFrameworkNames);

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/WSDL2JavaOptionsValidator.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/WSDL2JavaOptionsValidator.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/WSDL2JavaOptionsValidator.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/WSDL2JavaOptionsValidator.java Sun Sep 24 15:50:13 2006
@@ -48,6 +48,8 @@
                     (WSDL2JavaConstants.FLATTEN_FILES_OPTION).equalsIgnoreCase(optionType) ||
                     (WSDL2JavaConstants.UNWRAP_PARAMETERS).equalsIgnoreCase(optionType) ||
                     (WSDL2JavaConstants.BACKWORD_COMPATIBILITY_OPTION).equalsIgnoreCase(optionType) ||
+                    (WSDL2JavaConstants.SOURCE_FOLDER_NAME_OPTION).equalsIgnoreCase(optionType) ||
+                    (WSDL2JavaConstants.RESOURCE_FOLDER_OPTION).equalsIgnoreCase(optionType) ||
 
                     (WSDL2JavaConstants.OUTPUT_LOCATION_OPTION_LONG).equalsIgnoreCase(optionType) ||
                     (WSDL2JavaConstants.SERVER_SIDE_CODE_OPTION_LONG).equalsIgnoreCase(optionType) ||
@@ -69,6 +71,8 @@
                     (WSDL2JavaConstants.FLATTEN_FILES_OPTION_LONG).equalsIgnoreCase(optionType) ||
                     (WSDL2JavaConstants.UNWRAP_PARAMETERS_LONG).equalsIgnoreCase(optionType) ||
                     (WSDL2JavaConstants.REPOSITORY_PATH_OPTION_LONG).equalsIgnoreCase(optionType)||
+                    (WSDL2JavaConstants.SOURCE_FOLDER_NAME_OPTION_LONG).equalsIgnoreCase(optionType)||
+                    (WSDL2JavaConstants.RESOURCE_FOLDER_OPTION_LONG).equalsIgnoreCase(optionType)||
                     (WSDL2JavaConstants.BACKWORD_COMPATIBILITY_OPTION_LONG).equalsIgnoreCase(optionType)
             );
 

Modified: webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/XSLTIncludeResolver.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/XSLTIncludeResolver.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/XSLTIncludeResolver.java (original)
+++ webservices/axis2/trunk/java/modules/codegen/src/org/apache/axis2/wsdl/util/XSLTIncludeResolver.java Sun Sep 24 15:50:13 2006
@@ -102,7 +102,7 @@
 
     /**
      * returns an empty source
-     * @return
+     * @return stream source
      */
     private Source getEmptySource(){
         return new StreamSource(new ByteArrayInputStream("<xsl:stylesheet version=\"1.0\" xmlns:xsl=\"http://www.w3.org/1999/XSL/Transform\"/>".getBytes()));

Modified: webservices/axis2/trunk/java/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java?view=diff&rev=449519&r1=449518&r2=449519
==============================================================================
--- webservices/axis2/trunk/java/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java (original)
+++ webservices/axis2/trunk/java/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java Sun Sep 24 15:50:13 2006
@@ -337,13 +337,15 @@
 
         private File location;
         private boolean flatten = false;
-        private static final String RESOURCE_DIR_NAME = "resources";
-        private static final String SOURCE_DIR_NAME = "src";
-        private static final String JAVA_FILE_EXTENSION = ".java";
+        private  String resourceDirName;
+        private  String srcDirName;
+        private  static final String JAVA_FILE_EXTENSION = ".java";
 
         private Axis2Filer(CodeGenConfiguration config) {
             location = config.getOutputLocation();
             flatten = config.isFlattenFiles();
+            resourceDirName = config.getResourceLocation();
+            srcDirName = config.getSourceLocation();
         }
 
         public OutputStream createBinaryFile(String typename)
@@ -351,7 +353,7 @@
             File resourcesDirectory =
                     flatten?
                             location:
-                            new File(location, RESOURCE_DIR_NAME);
+                            new File(location, resourceDirName);
 
             if (!resourcesDirectory.exists()) {
                 resourcesDirectory.mkdirs();
@@ -370,7 +372,7 @@
             File outputDir =
                     flatten?
                             location:
-                            new File(location, SOURCE_DIR_NAME);
+                            new File(location, srcDirName);
 
             if (!outputDir.exists()) {
                 outputDir.mkdirs();
@@ -478,6 +480,9 @@
         }
     }
 
+    /**
+     * Axis2 specific entity resolver
+     */
     private static class Axis2EntityResolver implements EntityResolver {
         private XmlSchema[] schemas;
         private String baseUri;



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org


Mime
View raw message