org.gradle.api.tasks.ScalaSourceSet Java Examples

The following examples show how to use org.gradle.api.tasks.ScalaSourceSet. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: SourceSetUtils.java    From transport with BSD 2-Clause "Simplified" License 5 votes vote down vote up
/**
 * Returns the {@link SourceDirectorySet} for a given {@link SourceSet} depending on the language of the sources
 */
static SourceDirectorySet getSourceDirectorySet(SourceSet sourceSet, Language language) {
  switch (language) {
    case JAVA:
      return sourceSet.getJava();
    case SCALA:
      Convention sourceSetConvention = (Convention) InvokerHelper.getProperty(sourceSet, "convention");
      ScalaSourceSet scalaSourceSet = sourceSetConvention.getPlugin(ScalaSourceSet.class);
      return scalaSourceSet.getScala();
    default:
      throw new UnsupportedOperationException("Language " + language + " not supported");
  }
}
 
Example #2
Source File: DefaultScalaSourceSet.java    From pushfish-android with BSD 2-Clause "Simplified" License 4 votes vote down vote up
public ScalaSourceSet scala(Closure configureClosure) {
    ConfigureUtil.configure(configureClosure, getScala());
    return this;
}
 
Example #3
Source File: DefaultScalaSourceSet.java    From pushfish-android with BSD 2-Clause "Simplified" License 4 votes vote down vote up
public ScalaSourceSet scala(Closure configureClosure) {
    ConfigureUtil.configure(configureClosure, getScala());
    return this;
}
 
Example #4
Source File: DefaultScalaSourceSet.java    From Pushjet-Android with BSD 2-Clause "Simplified" License 4 votes vote down vote up
public ScalaSourceSet scala(Closure configureClosure) {
    ConfigureUtil.configure(configureClosure, getScala());
    return this;
}
 
Example #5
Source File: DefaultScalaSourceSet.java    From Pushjet-Android with BSD 2-Clause "Simplified" License 4 votes vote down vote up
public ScalaSourceSet scala(Closure configureClosure) {
    ConfigureUtil.configure(configureClosure, getScala());
    return this;
}