edu.umd.cs.findbugs.annotations.SuppressFBWarnings ).
There are another set of annotations used by an experimental detector for unclosed resources:
| Modifier and Type | Annotation and Description |
|---|---|
| public @interface | CheckForNull
The annotated element might be null, and uses of the element should check for null. |
| public @interface | CheckReturnValue
This annotation is used to denote a method whose return value should always be checked when invoking the method. |
| public @interface | CleanupObligation
Mark a class or interface as a resource type requiring cleanup. |
| public @interface | CreatesObligation
Mark a constructor or method as creating a resource which requires cleanup. |
| public @interface | DefaultAnnotation
Indicates that all members of the class or package should be annotated with the default value of the supplied annotation class. |
| public @interface | DefaultAnnotationForFields
Indicates that all members of the class or package should be annotated with the default value of the supplied annotation class. |
| public @interface | DefaultAnnotationForMethods
Indicates that all members of the class or package should be annotated with the default value of the supplied annotation class. |
| public @interface | DefaultAnnotationForParameters
Indicates that all members of the class or package should be annotated with the default value of the supplied annotation class. |
| public @interface | DesireNoWarning
Deprecated
The annotation based approach is useless for lambdas. Write expectations using Annotation indicating that no FindBugs warnings of the specified type
is desired.
edu.umd.cs.findbugs.test.matcher.BugInstanceMatcher matchers in test source directory
|
| public @interface | DesireWarning
Deprecated
The annotation based approach is useless for lambdas. Write expectations using Annotation indicating that a FindBugs warning is desired.
edu.umd.cs.findbugs.test.matcher.BugInstanceMatcher matchers in test source directory
|
| public @interface | DischargesObligation
Mark a method as cleaning up a resource. |
| public @interface | ExpectWarning
Deprecated
The annotation based approach is useless for lambdas. Write expectations using Annotation indicating that a FindBugs warning is expected.
edu.umd.cs.findbugs.test.matcher.BugInstanceMatcher matchers in test source directory
|
| public @interface | NonNull
The annotated element must not be null. |
| public @interface | NoWarning
Deprecated
The annotation based approach is useless for lambdas. Write expectations using Annotation indicating that no FindBugs warning is expected.
edu.umd.cs.findbugs.test.matcher.BugInstanceMatcher matchers in test source directory
|
| public @interface | Nullable
The annotated element could be null under some circumstances. |
| public @interface | OverrideMustInvoke
Used to annotate a method that, if overridden, must (or should) be invoked by an invocation on super in the overriding method. |
| public @interface | PossiblyNull
Deprecated
- use CheckForNull instead; the name of which more clearly
indicates that not only could the value be null, but that good
coding practice requires that the value be checked for null.
The annotated element should might be null, and uses of the element should
check for null.
|
| public @interface | ReturnValuesAreNonnullByDefault
This annotation can be applied to a package, class or method to indicate that the methods in that element have nonnull return values by default unless there is:
|
| public @interface | SuppressFBWarnings
Used to suppress FindBugs warnings. |
| public @interface | SuppressWarnings
Deprecated
- Use Was used to suppress FindBugs warnings but generates name conflicts with SuppressFBWarnings instead
java.
|
| public @interface | UnknownNullness
Used to indicate that the nullness of element is unknown, or may vary in unknown ways in subclasses. |
| Modifier and Type | Enum and Description |
|---|---|
| public enum | Confidence
Describes the confidence with which FindBugs reports a bug instance. |
| public enum | Priority
Deprecated
use
Confidence instead
|
| public enum | When
Deprecated
|