Generate Java code from multiple wsdls using gradle

You could use the ant task and Gradle’s ant integration

eg

apply plugin: java
ext {
    wsdlDir = 'src/main/wsdl'
}
configurations {
    axis
}
dependencies {
    axis 'org.apache.axis2:axis2-ant-plugin:1.7.8'
}
task generateCode {
   inputs.dir wsdlDir
   outputs.dir "$buildDir/codegen"
   doLast {
      ant.taskdef(
         name: 'codegen', 
         classname: 'org.apache.axis2.tool.ant.AntCodegenTask', 
         classpath: configurations.axis.asPath 
      )
      ant.codegen(
         wsdlfilename:"$wsdlDir/OfferCodeService-v5.wsdl",
         output: "$buildDir/codegen"
      )
      ant.codegen(    
         wsdlfilename:"$wsdlDir/ProductOfferingService_v11.wsdl",
         output: "$buildDir/codegen",
         syncOnly: 'true'
      )
      // etc
   }
}
compileJava.dependsOn generateCode
sourceSets.main.java.srcDir "$buildDir/codegen"