@CacheableTask open class Checkstyle : SourceTask, VerificationTask, Reporting<CheckstyleReports>
Runs Checkstyle against some source files.
Checkstyle() |
open fun getAntBuilder(): IsolatedAntBuilder |
|
open fun getCheckstyleClasspath(): FileCollection
The class path containing the Checkstyle library to be used. |
|
open fun getClasspath(): FileCollection
The class path containing the compiled classes for the source files to be analyzed. |
|
open fun getConfig(): TextResource
The Checkstyle configuration to use. Replaces the |
|
open fun getConfigDir(): File
Path to other Checkstyle configuration files. This path will be exposed as the variable |
|
open fun getConfigFile(): File
The Checkstyle configuration file to use. |
|
open fun getConfigProperties(): MutableMap<String, Any>
The properties available for use in the configuration file. These are substituted into the configuration file. |
|
open fun getIgnoreFailures(): Boolean
Whether or not this task will ignore failures and continue running the build. |
|
open fun getMaxErrors(): Int
The maximum number of errors that are tolerated before breaking the build or setting the failure property. |
|
open fun getMaxWarnings(): Int
The maximum number of warnings that are tolerated before breaking the build or setting the failure property. |
|
open fun getObjectFactory(): ObjectFactory
Injects and returns an instance of org.gradle.api.model.ObjectFactory. |
|
fun getReports(): CheckstyleReports
The reports to be generated by this task. |
|
open fun getSource(): FileTree
{@inheritDoc} The sources for this task are relatively relocatable even though it produces output that includes absolute paths. This is a compromise made to ensure that results can be reused between different builds. The downside is that up-to-date results, or results loaded from cache can show different absolute paths than would be produced if the task was executed. |
|
open fun isIgnoreFailures(): Boolean
Whether this task will ignore failures and continue running the build. |
|
open fun isShowViolations(): Boolean
Whether rule violations are to be displayed on the console. |
|
open fun reports(closure: Closure<Any>): CheckstyleReports open fun reports(configureAction: Action<in CheckstyleReports>): CheckstyleReports
Configures the reports to be generated by this task. The contained reports can be configured by name and closures. Example:
|
|
open fun run(): Unit |
|
open fun setCheckstyleClasspath(checkstyleClasspath: FileCollection): Unit
The class path containing the Checkstyle library to be used. |
|
open fun setClasspath(classpath: FileCollection): Unit
The class path containing the compiled classes for the source files to be analyzed. |
|
open fun setConfig(config: TextResource): Unit
The Checkstyle configuration to use. Replaces the |
|
open fun setConfigDir(configDir: Provider<File>): Unit
Path to other Checkstyle configuration files. This path will be exposed as the variable |
|
open fun setConfigFile(configFile: File): Unit
The Checkstyle configuration file to use. |
|
open fun setConfigProperties(configProperties: MutableMap<String, Any>): Unit
The properties available for use in the configuration file. These are substituted into the configuration file. |
|
open fun setIgnoreFailures(ignoreFailures: Boolean): Unit
Whether this task will ignore failures and continue running the build. |
|
open fun setMaxErrors(maxErrors: Int): Unit
Set the maximum number of errors that are tolerated before breaking the build. |
|
open fun setMaxWarnings(maxWarnings: Int): Unit
Set the maximum number of warnings that are tolerated before breaking the build. |
|
open fun setShowViolations(showViolations: Boolean): Unit
Whether rule violations are to be displayed on the console. |
open fun exclude(vararg excludes: String): SourceTask open fun exclude(excludes: MutableIterable<String>): SourceTask open fun exclude(excludeSpec: Spec<FileTreeElement>): SourceTask open fun exclude(excludeSpec: Closure<Any>): SourceTask
{@inheritDoc} |
|
open fun getExcludes(): MutableSet<String>
{@inheritDoc} |
|
open fun getIncludes(): MutableSet<String>
{@inheritDoc} |
|
open fun include(vararg includes: String): SourceTask open fun include(includes: MutableIterable<String>): SourceTask open fun include(includeSpec: Spec<FileTreeElement>): SourceTask open fun include(includeSpec: Closure<Any>): SourceTask
{@inheritDoc} |
|
open fun setExcludes(excludes: MutableIterable<String>): SourceTask
{@inheritDoc} |
|
open fun setIncludes(includes: MutableIterable<String>): SourceTask
{@inheritDoc} |
|
open fun setSource(source: FileTree): Unit
Sets the source for this task. open fun setSource(source: Any): Unit
Sets the source for this task. The given source object is evaluated as per |
|
open fun source(vararg sources: Any): SourceTask
Adds some source to this task. The given source objects will be evaluated as per |