axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From blorit...@apache.org
Subject cvs commit: xml-axis/java/src/org/apache/axis/wsdl Emitter.java
Date Mon, 15 Oct 2001 20:02:24 GMT
bloritsch    01/10/15 13:02:24

  Modified:    java/src/org/apache/axis/wsdl Emitter.java
  Log:
  Handle cases where no package name exists.
  
  Revision  Changes    Path
  1.51      +66 -11    xml-axis/java/src/org/apache/axis/wsdl/Emitter.java
  
  Index: Emitter.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/wsdl/Emitter.java,v
  retrieving revision 1.50
  retrieving revision 1.51
  diff -u -r1.50 -r1.51
  --- Emitter.java	2001/10/15 15:32:02	1.50
  +++ Emitter.java	2001/10/15 20:02:24	1.51
  @@ -505,8 +505,13 @@
           String fileName = nameValue + ".java";
   
           this.fileList.add(packageDirName + fileName);
  -        this.classList.add(packageName + "." + nameValue);
   
  +        if (packageName == null) {
  +            this.classList.add(nameValue);
  +        } else {
  +            this.classList.add(packageName + "." + nameValue);
  +        }
  +
           PrintWriter interfacePW = printWriter (fileName);
           if (bVerbose)
               System.out.println("Generating portType interface: " + fileName);
  @@ -538,7 +543,12 @@
           String fileName = nameValue + ".java";
   
           this.fileList.add(packageDirName + fileName);
  -        this.classList.add(packageName +  "." + nameValue);
  +
  +        if (packageName == null) {
  +            this.classList.add(nameValue);
  +        } else {
  +            this.classList.add(packageName + "." + nameValue);
  +        }
   
           PrintWriter interfacePW = printWriter(fileName);
           if (bVerbose)
  @@ -921,8 +931,13 @@
           }
   
           this.fileList.add(packageDirName + fileName);
  -        this.classList.add(packageName +  "." + exceptionName);
   
  +        if (packageName == null) {
  +            this.classList.add(exceptionName);
  +        } else {
  +            this.classList.add(packageName + "." + exceptionName);
  +        }
  +
           PrintWriter pw = printWriter(fileName);
   
           if (bVerbose)
  @@ -1001,7 +1016,12 @@
           String stubFileName = stubName + ".java";
   
           this.fileList.add(packageDirName + stubFileName);
  -        this.classList.add(packageName +  "." + stubName);
  +
  +        if (packageName == null) {
  +            this.classList.add(stubName);
  +        } else {
  +            this.classList.add(packageName + "." + stubName);
  +        }
   
           PrintWriter stubPW = printWriter(stubFileName);
           if (bVerbose)
  @@ -1080,7 +1100,12 @@
               String skelFileName = skelName + ".java";
   
               this.fileList.add(packageDirName + skelFileName);
  -            this.classList.add(packageName +  "." + skelName);
  +
  +            if (packageName == null) {
  +                this.classList.add(skelName);
  +            } else {
  +                this.classList.add(packageName + "." + skelName);
  +            }
   
               skelPW = printWriter(skelFileName);
               String implType = portTypeName + " impl";
  @@ -1108,8 +1133,13 @@
               String implFileName = implName + ".java";
   
               this.fileList.add(packageDirName + implFileName);
  -            this.classList.add(packageName +  "." + implName);
   
  +            if (packageName == null) {
  +                this.classList.add(implName);
  +            } else {
  +                this.classList.add(packageName + "." + implName);
  +            }
  +
               if (!fileExists (implFileName)) {
                   implPW = printWriter(implFileName);
                   if (bVerbose)
  @@ -1455,8 +1485,13 @@
           String fileName = serviceName + ".java";
   
           this.fileList.add(packageDirName + fileName);
  -        this.classList.add(packageName +  "." + serviceName);
   
  +        if (packageName == null) {
  +            this.classList.add(serviceName);
  +        } else {
  +            this.classList.add(packageName + "." + serviceName);
  +        }
  +
           PrintWriter servicePW = printWriter(fileName);
           TestCaseEmitter testFactory = null;
   
  @@ -1469,7 +1504,12 @@
               String testCaseFileName = testCase + ".java";
   
               this.fileList.add(packageDirName + testCaseFileName);
  -            this.classList.add(packageName +  "." + testCase);
  +
  +            if (packageName == null) {
  +                this.classList.add(testCase);
  +            } else {
  +                this.classList.add(packageName + "." + testCase);
  +            }
   
               testFactory = new TestCaseEmitter(this.printWriter(testCaseFileName),
                                                 this.packageName,
  @@ -1829,8 +1869,13 @@
           String fileName = javaName + ".java";
   
           this.fileList.add(packageDirName + fileName);
  -        this.classList.add(packageName + "." + javaName);
   
  +       if (packageName == null) {
  +           this.classList.add(javaName);
  +       } else {
  +           this.classList.add(packageName + "." + javaName);
  +       }
  +
           PrintWriter typePW = printWriter(fileName);
           if (bVerbose)
               System.out.println("Generating type implementation: " + fileName);
  @@ -1909,7 +1954,12 @@
           String fileName = javaName + ".java";
   
           this.fileList.add(packageDirName + fileName);
  -        this.classList.add(packageName +  "." + javaName);
  +
  +       if (packageName == null) {
  +           this.classList.add(javaName);
  +       } else {
  +           this.classList.add(packageName + "." + javaName);
  +       }
   
           PrintWriter typePW = printWriter(fileName);
           if (bVerbose)
  @@ -1936,7 +1986,12 @@
           String fileName = javaName + "Holder.java";
   
           this.fileList.add(packageDirName + fileName);
  -        this.classList.add(packageName + "." + javaName);
  +
  +        if (packageName == null) {
  +            this.classList.add(javaName);
  +        } else {
  +            this.classList.add(packageName + "." + javaName);
  +        }
   
           PrintWriter pw = printWriter(fileName);
           if (bVerbose)
  
  
  

Mime
View raw message