Groovy Documentation

org.gradle.api.tasks
[Java] Interface SourceSetContainer

org.gradle.api.NamedDomainObjectSet
  java.lang.Iterable
      org.gradle.api.tasks.SourceSetContainer
          org.gradle.api.DomainObjectCollection
              java.util.Collection
                  org.gradle.api.NamedDomainObjectCollection
                      org.gradle.api.NamedDomainObjectContainer
All Superinterfaces:
NamedDomainObjectSet, DomainObjectCollection, NamedDomainObjectCollection, NamedDomainObjectContainer

public interface SourceSetContainer
extends NamedDomainObjectContainer, NamedDomainObjectSet

A SourceSetContainer manages a set of SourceSet objects.


Method Summary
SourceSet add(java.lang.String name)

Adds a source set with the given name.

SourceSet add(java.lang.String name, groovy.lang.Closure configureClosure)

Adds a source set with the given name.

 
Methods inherited from interface NamedDomainObjectSet
findAll, matching, matching, withType
 
Methods inherited from interface NamedDomainObjectContainer
configure, create, create
 
Methods inherited from interface NamedDomainObjectSet
findAll, matching, matching, withType
 
Methods inherited from interface org.gradle.util.Configurable
org.gradle.util.Configurable#configure(groovy.lang.Closure)
 
Methods inherited from class java.lang.Object
java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()
 

Method Detail

add

public SourceSet add(java.lang.String name)
Adds a source set with the given name.
throws:
org.gradle.api.InvalidUserDataException when a source set with the given name already exists in this container.
Parameters:
name - The name of the new source set.
Returns:
The newly added source set.


add

public SourceSet add(java.lang.String name, groovy.lang.Closure configureClosure)
Adds a source set with the given name. The given configuration closure is executed against the source set before it is returned from this method.
throws:
InvalidUserDataException when a source set with the given name already exists in this container.
Parameters:
name - The name of the new source set.
configureClosure - The closure to use to configure the source set.
Returns:
The newly added source set.


 

Groovy Documentation