Package crappyjava.gradle
Class CrappyJavaExtension
java.lang.Object
crappyjava.gradle.CrappyJavaExtension
crappyJava { ... } block. Values become the conventions of the crap task.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.gradle.api.provider.Property<Boolean>Fail the build when any method is above the threshold.org.gradle.api.provider.Property<Boolean>List every method instead of only crappy ones.org.gradle.api.provider.Property<Double>CRAP score above which a method is crappy.org.gradle.api.provider.Property<Integer>getTop()List the n worst methods regardless of threshold; 0 disables.voidsetThreshold(Number value) Accepts any number so Groovy DSL can writethreshold = 10orthreshold = 7.5.
-
Constructor Details
-
CrappyJavaExtension
@Inject public CrappyJavaExtension(org.gradle.api.model.ObjectFactory objects)
-
-
Method Details
-
getThreshold
CRAP score above which a method is crappy. Default 30. -
setThreshold
Accepts any number so Groovy DSL can writethreshold = 10orthreshold = 7.5. -
getFailOnViolation
Fail the build when any method is above the threshold. Default true. -
getShowAll
List every method instead of only crappy ones. Default false. -
getTop
List the n worst methods regardless of threshold; 0 disables. Default 0.
-