Reply to comment

groovy can't handle the output of wsdl2java

Oh, up until 1 am last night with this issue.

I ran a wsdl2java against the stitches webservice and have a nice suite of classes that I can use to connect o stitches.  i created a groovy class to instantiate the client, and it WILL NOT compile.

Turns out the the wsdl2java generated a lowercase classtype "stitches" which is an interface.

Hence, while this would compile in java, it does not compile in groovy

stitches mystitches = null

Posted the issue on the groovy list...  Hopefully someone will at least give me an idea of how to proceed.

 

Hi,

I have a groovy file with a reference to a lowercase type. It won't compile. I made up a simple example that illustrates my problem. In my real problem, I am trying to reference some java that came from wsdl2java, so it's not quite so simple as renaming a class.

Thanks for any hints.

Base Directory: /Users/prhodes/Documents/workspace-stitches/stitches-client
Running script /Users/prhodes/local/grails/grails-1.1/scripts/Compile.groovy
Environment set to development
[groovyc] Compiling 2 source files to /Users/prhodes/.grails/1.1/projects/stitches-client/classes
[groovyc] org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed, /Users/prhodes/Documents/workspace-stitches/stitches-client/grails-app/services/StitchesService.groovy: 10: unexpected token: mylowercase @ line 10, column 5.
[groovyc] mylowercase mystitches = null
[groovyc] ^
[groovyc]
[groovyc] 1 error

Here is my groovy file:

import org.authsum.stitches.test.mylowercase
class StitchesService {
mylowercase mystitches = null
}

Here is my java file, (lowercase.java)
package org.authsum.stitches.main;

public class mylowercase {

}


Reply

  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options