Using gradle to generate eclipse projects for EJB Module
I want to generate project and settings for a EAR project, a EJB client jar and a EJB module but i was not able to inser开发者_如何学编程t new facets to the eclipseWtp task, tried many combinations based on the documentation on gradle website.
tried things like the following and always got Premature end of file error.
eclipseWtp {
    beforeConfigured { wtp ->
        wtp.facets.add(new Facet('jst.ejb','3.1'))
    }
}
eclipseWtp {    
    facet(['name':'jst.ejb','version':'3.1'])
}
Make sure that both war and eclipse plugins are applied on the project. Then it will work correctly, eg.:
apply plugin: 'war'
apply plugin: 'eclipse'
eclipseWtp.facet(name: 'jst.ejb', version: '3.1')
 
         加载中,请稍侯......
 加载中,请稍侯......
      
精彩评论