You are viewing a plain text version of this content. The canonical link for it is here.
Posted to wsrf-dev@ws.apache.org by sc...@apache.org on 2004/12/24 00:47:59 UTC

svn commit: r123254 - /incubator/apollo/trunk/src/java/org/apache/ws/resource/Wsdl2Java.java

Author: scamp
Date: Thu Dec 23 15:47:58 2004
New Revision: 123254

URL: http://svn.apache.org/viewcvs?view=rev&rev=123254
Log:

Modified:
   incubator/apollo/trunk/src/java/org/apache/ws/resource/Wsdl2Java.java

Modified: incubator/apollo/trunk/src/java/org/apache/ws/resource/Wsdl2Java.java
Url: http://svn.apache.org/viewcvs/incubator/apollo/trunk/src/java/org/apache/ws/resource/Wsdl2Java.java?view=diff&rev=123254&p1=incubator/apollo/trunk/src/java/org/apache/ws/resource/Wsdl2Java.java&r1=123253&p2=incubator/apollo/trunk/src/java/org/apache/ws/resource/Wsdl2Java.java&r2=123254
==============================================================================
--- incubator/apollo/trunk/src/java/org/apache/ws/resource/Wsdl2Java.java	(original)
+++ incubator/apollo/trunk/src/java/org/apache/ws/resource/Wsdl2Java.java	Thu Dec 23 15:47:58 2004
@@ -179,7 +179,8 @@
    public void generate(  )
    throws Exception
    {
-      generateXmlBeans(  );
+      //generateXmlBeans(  );
+      initVelocityProperties(  );
       for ( int i = 0; i < m_wsdlFiles.length; i++ )
       {
          WSDLReader wsdlReader = WSDLFactory.newInstance(  ).newWSDLReader(  );
@@ -206,10 +207,10 @@
    throws ParseException
    {
       CommandLine cmdLine = new PosixParser(  ).parse( CMD_LINE_OPTIONS, args, true );
-      checkForRequiredOption( cmdLine, LONG_OPT_SRC_OUTPUT_DIR );
-      checkForRequiredOption( cmdLine, LONG_OPT_CLASSES_OUTPUT_DIR );
-      File    srcOutputDir     = new File( cmdLine.getOptionValue( LONG_OPT_SRC_OUTPUT_DIR ) );
-      File    classesOutputDir = new File( cmdLine.getOptionValue( LONG_OPT_CLASSES_OUTPUT_DIR ) );
+      checkForRequiredOption( cmdLine, "s" );
+      checkForRequiredOption( cmdLine, "c" );
+      File    srcOutputDir     = new File( cmdLine.getOptionValue( "s" ) );
+      File    classesOutputDir = new File( cmdLine.getOptionValue( "c" ) );
       Options options          = new Wsdl2Java.Options(  );
       boolean singleton = false;
       String resourceKey = null;
@@ -295,7 +296,6 @@
    private void generateSkeletonCode(ResourceDefinition resourceDef, String wsdlFileName)
    throws Exception
    {
-      initVelocityProperties(  );
       String serviceName = StringUtils.capitalize(resourceDef.getName());
       try
       {
@@ -311,7 +311,7 @@
          String javaPackageName = GenerationUtils.getJavaPackageName(targetNamespace);
          javaPackageName = javaPackageName.replace('.','/');
          File packageDir = new File(m_srcOutputDir, javaPackageName);
-
+         packageDir.mkdirs();
          File generatedSrc = new File( packageDir, "Abstract" + serviceName + "Service.java" );
          writeGeneratedSrcFile( context,
                                 "templates/AbstractService.vm",
@@ -387,7 +387,7 @@
         props.setServiceImplements(ImplementsListBuilder.getServiceImplementsList(resourceDef));
         props.setNamespace(targetNamespace);
         props.setPrefix(GenerationUtils.getPrefix(targetNamespace));
-        props.setCustomMappings();
+        props.setCustomMappings(GenerationUtils.getOperationInfoMap(resourceDef));
 
         QName[] customPropertyNames = resourceDef.getCustomPropertyNames();
         Map customPropMap = new HashMap();

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