Detekt

@CacheableTask
abstract class Detekt @Inject constructor(objects: ObjectFactory, workerExecutor: WorkerExecutor, providers: ProviderFactory) : SourceTask

Constructors

Link copied to clipboard
@Inject
constructor(objects: ObjectFactory, workerExecutor: WorkerExecutor, providers: ProviderFactory)

Properties

Link copied to clipboard
@get:Input
abstract val allRules: Property<Boolean>
Link copied to clipboard
@get:Input
@get:Optional
abstract val apiVersion: Property<String>
Link copied to clipboard
@get:Input
abstract val autoCorrect: Property<Boolean>
Link copied to clipboard
@get:InputFiles
@get:Optional
@get:PathSensitive(value = PathSensitivity.RELATIVE)
abstract val baseline: RegularFileProperty
Link copied to clipboard
@get:Input
@get:Optional
abstract val basePath: Property<String>

Respect only the file path for incremental build. Using @InputFile respects both file path and content.

Link copied to clipboard
@get:Input
abstract val buildUponDefaultConfig: Property<Boolean>
Link copied to clipboard
@get:Classpath
@get:Optional
abstract val classpath: ConfigurableFileCollection
Link copied to clipboard
@get:InputFiles
@get:Optional
@get:PathSensitive(value = PathSensitivity.RELATIVE)
abstract val config: ConfigurableFileCollection
Link copied to clipboard
@get:Console
abstract val debug: Property<Boolean>
Link copied to clipboard
@get:Classpath
abstract val detektClasspath: ConfigurableFileCollection
Link copied to clipboard
@get:Input
abstract val disableDefaultRuleSets: Property<Boolean>
Link copied to clipboard
@get:Input
@get:Optional
abstract val failOnSeverity: Property<FailOnSeverity>
Link copied to clipboard
@get:Input
@get:Incubating
abstract val freeCompilerArgs: ListProperty<String>
Link copied to clipboard
@get:Internal
abstract val friendPaths: ConfigurableFileCollection
Link copied to clipboard
@get:Input
abstract val ignoreFailures: Property<Boolean>
Link copied to clipboard
@get:Internal
abstract val jdkHome: DirectoryProperty
Link copied to clipboard
@get:Input
@get:Optional
abstract val jvmTarget: Property<String>
Link copied to clipboard
@get:Input
@get:Optional
abstract val languageVersion: Property<String>
Link copied to clipboard
@get:Input
abstract val noJdk: Property<Boolean>
Link copied to clipboard
@get:Input
abstract val optIn: ListProperty<String>
Link copied to clipboard
@get:Internal
abstract val parallel: Property<Boolean>
Link copied to clipboard
@get:Classpath
abstract val pluginClasspath: ConfigurableFileCollection
Link copied to clipboard

Functions

Link copied to clipboard
fun check()
Link copied to clipboard
@InputFiles
@SkipWhenEmpty
@IgnoreEmptyDirectories
@PathSensitive(value = PathSensitivity.RELATIVE)
open override fun getSource(): FileTree
Link copied to clipboard
fun reports(configure: Action<DetektReports>)