api / org.gradle.plugins.ide.eclipse.model / EclipseModel

EclipseModel

open class EclipseModel

DSL-friendly model of the Eclipse project information. First point of entry for customizing Eclipse project generation.

 apply plugin: 'java' apply plugin: 'eclipse' apply plugin: 'eclipse-wtp' //for web projects only eclipse { pathVariables 'GRADLE_HOME': file('/best/software/gradle'), 'TOMCAT_HOME': file('../tomcat') project { //see docs for EclipseProject } classpath { //see docs for EclipseClasspath } wtp { //see docs for EclipseWtp } } 
More examples in docs for EclipseProject, EclipseClasspath, EclipseWtp

Constructors

<init>

EclipseModel()

DSL-friendly model of the Eclipse project information. First point of entry for customizing Eclipse project generation.

 apply plugin: 'java' apply plugin: 'eclipse' apply plugin: 'eclipse-wtp' //for web projects only eclipse { pathVariables 'GRADLE_HOME': file('/best/software/gradle'), 'TOMCAT_HOME': file('../tomcat') project { //see docs for EclipseProject } classpath { //see docs for EclipseClasspath } wtp { //see docs for EclipseWtp } } 
More examples in docs for EclipseProject, EclipseClasspath, EclipseWtp

Functions

classpath

open fun classpath(closure: Closure<Any>): Unit
open fun classpath(action: Action<in EclipseClasspath>): Unit

Configures eclipse classpath information

For examples see docs for EclipseClasspath

getClasspath

open fun getClasspath(): EclipseClasspath

Configures eclipse classpath information

For examples see docs for EclipseClasspath

getJdt

open fun getJdt(): EclipseJdt

Configures eclipse java compatibility information (jdt)

For examples see docs for EclipseProject

getProject

open fun getProject(): EclipseProject

Configures eclipse project information

For examples see docs for EclipseProject

getWtp

open fun getWtp(): EclipseWtp

Configures eclipse wtp information

For examples see docs for EclipseWtp

jdt

open fun jdt(closure: Closure<Any>): Unit
open fun jdt(action: Action<in EclipseJdt>): Unit

Configures eclipse java compatibility information (jdt)

For examples see docs for EclipseProject

pathVariables

open fun pathVariables(pathVariables: MutableMap<String, File>): Unit

Adds path variables to be used for replacing absolute paths in classpath entries.

If the beginning of the absolute path of a library or other path-related element matches a value of a variable, a variable entry is used. The matching part of the library path is replaced with the variable name.

For example see docs for EclipseModel

project

open fun project(closure: Closure<Any>): Unit
open fun project(action: Action<in EclipseProject>): Unit

Configures eclipse project information

For examples see docs for EclipseProject

setClasspath

open fun setClasspath(classpath: EclipseClasspath): Unit

setJdt

open fun setJdt(jdt: EclipseJdt): Unit

setProject

open fun setProject(project: EclipseProject): Unit

setWtp

open fun setWtp(wtp: EclipseWtp): Unit

wtp

open fun wtp(closure: Closure<Any>): Unit
open fun wtp(action: Action<in EclipseWtp>): Unit

Configures eclipse wtp information

For examples see docs for EclipseWtp

Extension Properties

ext

val EclipseModel.ext: ExtraPropertiesExtension

Retrieves the ext extension.

Extension Functions

ext

fun EclipseModel.ext(configure: ExtraPropertiesExtension.() -> Unit): Unit

Configures the ext extension.