Package com.github.sevntu.checkstyle.checks.design
Contains the Class Design checks that
are bundled with the main distribution.
-
Class Summary Class Description AvoidConditionInversionCheck This Check helps to catch condition inversion cases which could be rewritten in a more
readable manner
There're cases where it's justified to get rid of such inversion without changing
the main logic.CauseParameterInExceptionCheck Checks that any Exception class which matches the defined className regexp have at least one constructor with Exception cause as a parameter.CheckstyleTestMakeupCheck Custom check to ensure Checkstyle tests are designed correctly.ChildBlockLengthCheck This check detects the child blocks, which length is more then 80% of parent block length.ConstructorWithoutParamsCheck This check prohibits usage of parameterless constructors, including the default ones.ForbidWildcardAsReturnTypeCheck Prevents using wildcards as return type of methods.HideUtilityClassConstructorCheck Make sure that utility classes (classes that contain only static methods) do not have a public constructor.InnerClassCheck Check nested (internal) classes to be declared at the bottom of the class after all methods (fields) declaration.NestedSwitchCheck This check ensures that there is no switch block inside other switch block.NoMainMethodInAbstractClassCheck Forbids main methods in abstract classes.PublicReferenceToPrivateTypeCheck This Check warns on propagation of inner private types to outer classes:
- Externally accessible method if it returns private inner type.
- Externally accessible field if its type is a private inner type.
These types could be private inner classes, interfaces or enumerations.
Examples:StaticMethodCandidateCheck Checks whetherprivate
methods can be declared asstatic
.