aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/lombok/core/handlers/HandlerUtil.java208
1 files changed, 200 insertions, 8 deletions
diff --git a/src/core/lombok/core/handlers/HandlerUtil.java b/src/core/lombok/core/handlers/HandlerUtil.java
index 3a7d6317..1f8e6964 100644
--- a/src/core/lombok/core/handlers/HandlerUtil.java
+++ b/src/core/lombok/core/handlers/HandlerUtil.java
@@ -79,32 +79,224 @@ public class HandlerUtil {
public static final List<String> NONNULL_ANNOTATIONS, BASE_COPYABLE_ANNOTATIONS;
static {
NONNULL_ANNOTATIONS = Collections.unmodifiableList(Arrays.asList(new String[] {
- "lombok.NonNull",
+ "android.annotation.NonNull",
"android.support.annotation.NonNull",
+ "com.sun.istack.internal.NotNull",
"edu.umd.cs.findbugs.annotations.NonNull",
"javax.annotation.Nonnull",
+ "javax.validation.constraints.NotNull",
+ "lombok.NonNull",
"org.checkerframework.checker.nullness.qual.NonNull",
"org.eclipse.jdt.annotation.NonNull",
+ "org.eclipse.jgit.annotations.NonNull",
"org.jetbrains.annotations.NotNull",
+ "org.jmlspecs.annotation.NonNull",
+ "org.netbeans.api.annotations.common.NonNull",
"org.springframework.lang.NonNull"
}));
BASE_COPYABLE_ANNOTATIONS = Collections.unmodifiableList(Arrays.asList(new String[] {
- "lombok.NonNull",
"android.support.annotation.NonNull",
- "edu.umd.cs.findbugs.annotations.NonNull",
- "javax.annotation.Nonnull",
- "org.checkerframework.checker.nullness.qual.NonNull",
- "org.eclipse.jdt.annotation.NonNull",
- "org.jetbrains.annotations.NotNull",
- "org.springframework.lang.NonNull",
"android.support.annotation.Nullable",
+ "edu.umd.cs.findbugs.annotations.NonNull",
"edu.umd.cs.findbugs.annotations.Nullable",
"edu.umd.cs.findbugs.annotations.UnknownNullness",
"javax.annotation.CheckForNull",
+ "javax.annotation.Nonnull",
"javax.annotation.Nullable",
+ "lombok.NonNull",
+ // To update Checker Framework annotations, run:
+ // grep --recursive --files-with-matches -e '^@Target\b.*TYPE_USE' $CHECKERFRAMEWORK/checker/src/main/java $CHECKERFRAMEWORK/framework/src/main/java | grep '\.java$' | sed 's/.*\/java\//\t\t\t"/' | sed 's/\.java$/",/' | sed 's/\//./g' | sort
+ "org.checkerframework.checker.compilermsgs.qual.CompilerMessageKey",
+ "org.checkerframework.checker.compilermsgs.qual.CompilerMessageKeyBottom",
+ "org.checkerframework.checker.compilermsgs.qual.UnknownCompilerMessageKey",
+ "org.checkerframework.checker.fenum.qual.AwtAlphaCompositingRule",
+ "org.checkerframework.checker.fenum.qual.AwtColorSpace",
+ "org.checkerframework.checker.fenum.qual.AwtCursorType",
+ "org.checkerframework.checker.fenum.qual.AwtFlowLayout",
+ "org.checkerframework.checker.fenum.qual.Fenum",
+ "org.checkerframework.checker.fenum.qual.FenumBottom",
+ "org.checkerframework.checker.fenum.qual.FenumTop",
+ "org.checkerframework.checker.fenum.qual.PolyFenum",
+ "org.checkerframework.checker.fenum.qual.SwingBoxOrientation",
+ "org.checkerframework.checker.fenum.qual.SwingCompassDirection",
+ "org.checkerframework.checker.fenum.qual.SwingElementOrientation",
+ "org.checkerframework.checker.fenum.qual.SwingHorizontalOrientation",
+ "org.checkerframework.checker.fenum.qual.SwingSplitPaneOrientation",
+ "org.checkerframework.checker.fenum.qual.SwingTextOrientation",
+ "org.checkerframework.checker.fenum.qual.SwingTitleJustification",
+ "org.checkerframework.checker.fenum.qual.SwingTitlePosition",
+ "org.checkerframework.checker.fenum.qual.SwingVerticalOrientation",
+ "org.checkerframework.checker.formatter.qual.Format",
+ "org.checkerframework.checker.formatter.qual.FormatBottom",
+ "org.checkerframework.checker.formatter.qual.InvalidFormat",
+ "org.checkerframework.checker.guieffect.qual.AlwaysSafe",
+ "org.checkerframework.checker.guieffect.qual.PolyUI",
+ "org.checkerframework.checker.guieffect.qual.UI",
+ "org.checkerframework.checker.i18nformatter.qual.I18nFormat",
+ "org.checkerframework.checker.i18nformatter.qual.I18nFormatBottom",
+ "org.checkerframework.checker.i18nformatter.qual.I18nFormatFor",
+ "org.checkerframework.checker.i18nformatter.qual.I18nInvalidFormat",
+ "org.checkerframework.checker.i18nformatter.qual.I18nUnknownFormat",
+ "org.checkerframework.checker.i18n.qual.LocalizableKey",
+ "org.checkerframework.checker.i18n.qual.LocalizableKeyBottom",
+ "org.checkerframework.checker.i18n.qual.Localized",
+ "org.checkerframework.checker.i18n.qual.UnknownLocalizableKey",
+ "org.checkerframework.checker.i18n.qual.UnknownLocalized",
+ "org.checkerframework.checker.index.qual.GTENegativeOne",
+ "org.checkerframework.checker.index.qual.IndexFor",
+ "org.checkerframework.checker.index.qual.IndexOrHigh",
+ "org.checkerframework.checker.index.qual.IndexOrLow",
+ "org.checkerframework.checker.index.qual.LengthOf",
+ "org.checkerframework.checker.index.qual.LessThan",
+ "org.checkerframework.checker.index.qual.LessThanBottom",
+ "org.checkerframework.checker.index.qual.LessThanUnknown",
+ "org.checkerframework.checker.index.qual.LowerBoundBottom",
+ "org.checkerframework.checker.index.qual.LowerBoundUnknown",
+ "org.checkerframework.checker.index.qual.LTEqLengthOf",
+ "org.checkerframework.checker.index.qual.LTLengthOf",
+ "org.checkerframework.checker.index.qual.LTOMLengthOf",
+ "org.checkerframework.checker.index.qual.NegativeIndexFor",
+ "org.checkerframework.checker.index.qual.NonNegative",
+ "org.checkerframework.checker.index.qual.PolyIndex",
+ "org.checkerframework.checker.index.qual.PolyLength",
+ "org.checkerframework.checker.index.qual.PolyLowerBound",
+ "org.checkerframework.checker.index.qual.PolySameLen",
+ "org.checkerframework.checker.index.qual.PolyUpperBound",
+ "org.checkerframework.checker.index.qual.Positive",
+ "org.checkerframework.checker.index.qual.SameLen",
+ "org.checkerframework.checker.index.qual.SameLenBottom",
+ "org.checkerframework.checker.index.qual.SameLenUnknown",
+ "org.checkerframework.checker.index.qual.SearchIndexBottom",
+ "org.checkerframework.checker.index.qual.SearchIndexFor",
+ "org.checkerframework.checker.index.qual.SearchIndexUnknown",
+ "org.checkerframework.checker.index.qual.SubstringIndexBottom",
+ "org.checkerframework.checker.index.qual.SubstringIndexFor",
+ "org.checkerframework.checker.index.qual.SubstringIndexUnknown",
+ "org.checkerframework.checker.index.qual.UpperBoundBottom",
+ "org.checkerframework.checker.index.qual.UpperBoundUnknown",
+ "org.checkerframework.checker.initialization.qual.FBCBottom",
+ "org.checkerframework.checker.initialization.qual.Initialized",
+ "org.checkerframework.checker.initialization.qual.UnderInitialization",
+ "org.checkerframework.checker.initialization.qual.UnknownInitialization",
+ "org.checkerframework.checker.interning.qual.Interned",
+ "org.checkerframework.checker.interning.qual.InternedDistinct",
+ "org.checkerframework.checker.interning.qual.PolyInterned",
+ "org.checkerframework.checker.interning.qual.UnknownInterned",
+ "org.checkerframework.checker.lock.qual.GuardedBy",
+ "org.checkerframework.checker.lock.qual.GuardedByBottom",
+ "org.checkerframework.checker.lock.qual.GuardedByUnknown",
+ "org.checkerframework.checker.lock.qual.GuardSatisfied",
+ "org.checkerframework.checker.nullness.qual.KeyFor",
+ "org.checkerframework.checker.nullness.qual.KeyForBottom",
+ "org.checkerframework.checker.nullness.qual.MonotonicNonNull",
+ "org.checkerframework.checker.nullness.qual.NonNull",
+ "org.checkerframework.checker.nullness.qual.NonRaw",
"org.checkerframework.checker.nullness.qual.Nullable",
+ "org.checkerframework.checker.nullness.qual.PolyKeyFor",
+ "org.checkerframework.checker.nullness.qual.PolyNull",
+ "org.checkerframework.checker.nullness.qual.PolyRaw",
+ "org.checkerframework.checker.nullness.qual.Raw",
+ "org.checkerframework.checker.nullness.qual.UnknownKeyFor",
+ "org.checkerframework.checker.optional.qual.MaybePresent",
+ "org.checkerframework.checker.optional.qual.PolyPresent",
+ "org.checkerframework.checker.optional.qual.Present",
+ "org.checkerframework.checker.propkey.qual.PropertyKey",
+ "org.checkerframework.checker.propkey.qual.PropertyKeyBottom",
+ "org.checkerframework.checker.propkey.qual.UnknownPropertyKey",
+ "org.checkerframework.checker.regex.qual.PolyRegex",
+ "org.checkerframework.checker.regex.qual.Regex",
+ "org.checkerframework.checker.regex.qual.RegexBottom",
+ "org.checkerframework.checker.regex.qual.UnknownRegex",
+ "org.checkerframework.checker.signature.qual.BinaryName",
+ "org.checkerframework.checker.signature.qual.BinaryNameInUnnamedPackage",
+ "org.checkerframework.checker.signature.qual.ClassGetName",
+ "org.checkerframework.checker.signature.qual.ClassGetSimpleName",
+ "org.checkerframework.checker.signature.qual.DotSeparatedIdentifiers",
+ "org.checkerframework.checker.signature.qual.FieldDescriptor",
+ "org.checkerframework.checker.signature.qual.FieldDescriptorForPrimitive",
+ "org.checkerframework.checker.signature.qual.FieldDescriptorForPrimitiveOrArrayInUnnamedPackage",
+ "org.checkerframework.checker.signature.qual.FullyQualifiedName",
+ "org.checkerframework.checker.signature.qual.Identifier",
+ "org.checkerframework.checker.signature.qual.IdentifierOrArray",
+ "org.checkerframework.checker.signature.qual.InternalForm",
+ "org.checkerframework.checker.signature.qual.MethodDescriptor",
+ "org.checkerframework.checker.signature.qual.PolySignature",
+ "org.checkerframework.checker.signature.qual.SignatureBottom",
+ "org.checkerframework.checker.signedness.qual.Constant",
+ "org.checkerframework.checker.signedness.qual.PolySignedness",
+ "org.checkerframework.checker.signedness.qual.Signed",
+ "org.checkerframework.checker.signedness.qual.SignednessBottom",
+ "org.checkerframework.checker.signedness.qual.UnknownSignedness",
+ "org.checkerframework.checker.signedness.qual.Unsigned",
+ "org.checkerframework.checker.tainting.qual.PolyTainted",
+ "org.checkerframework.checker.tainting.qual.Tainted",
+ "org.checkerframework.checker.tainting.qual.Untainted",
+ "org.checkerframework.checker.units.qual.A",
+ "org.checkerframework.checker.units.qual.Acceleration",
+ "org.checkerframework.checker.units.qual.Angle",
+ "org.checkerframework.checker.units.qual.Area",
+ "org.checkerframework.checker.units.qual.C",
+ "org.checkerframework.checker.units.qual.cd",
+ "org.checkerframework.checker.units.qual.Current",
+ "org.checkerframework.checker.units.qual.degrees",
+ "org.checkerframework.checker.units.qual.g",
+ "org.checkerframework.checker.units.qual.h",
+ "org.checkerframework.checker.units.qual.K",
+ "org.checkerframework.checker.units.qual.kg",
+ "org.checkerframework.checker.units.qual.km",
+ "org.checkerframework.checker.units.qual.km2",
+ "org.checkerframework.checker.units.qual.kmPERh",
+ "org.checkerframework.checker.units.qual.Length",
+ "org.checkerframework.checker.units.qual.Luminance",
+ "org.checkerframework.checker.units.qual.m",
+ "org.checkerframework.checker.units.qual.m2",
+ "org.checkerframework.checker.units.qual.Mass",
+ "org.checkerframework.checker.units.qual.min",
+ "org.checkerframework.checker.units.qual.mm",
+ "org.checkerframework.checker.units.qual.mm2",
+ "org.checkerframework.checker.units.qual.mol",
+ "org.checkerframework.checker.units.qual.mPERs",
+ "org.checkerframework.checker.units.qual.mPERs2",
+ "org.checkerframework.checker.units.qual.PolyUnit",
+ "org.checkerframework.checker.units.qual.radians",
+ "org.checkerframework.checker.units.qual.s",
+ "org.checkerframework.checker.units.qual.Speed",
+ "org.checkerframework.checker.units.qual.Substance",
+ "org.checkerframework.checker.units.qual.Temperature",
+ "org.checkerframework.checker.units.qual.Time",
+ "org.checkerframework.checker.units.qual.UnitsBottom",
+ "org.checkerframework.checker.units.qual.UnknownUnits",
+ "org.checkerframework.common.aliasing.qual.LeakedToResult",
+ "org.checkerframework.common.aliasing.qual.MaybeAliased",
+ "org.checkerframework.common.aliasing.qual.NonLeaked",
+ "org.checkerframework.common.aliasing.qual.Unique",
+ "org.checkerframework.common.reflection.qual.ClassBound",
+ "org.checkerframework.common.reflection.qual.ClassVal",
+ "org.checkerframework.common.reflection.qual.ClassValBottom",
+ "org.checkerframework.common.reflection.qual.MethodVal",
+ "org.checkerframework.common.reflection.qual.MethodValBottom",
+ "org.checkerframework.common.reflection.qual.UnknownClass",
+ "org.checkerframework.common.reflection.qual.UnknownMethod",
+ "org.checkerframework.common.subtyping.qual.Bottom",
+ "org.checkerframework.common.util.report.qual.ReportUnqualified",
+ "org.checkerframework.common.value.qual.ArrayLen",
+ "org.checkerframework.common.value.qual.ArrayLenRange",
+ "org.checkerframework.common.value.qual.BoolVal",
+ "org.checkerframework.common.value.qual.BottomVal",
+ "org.checkerframework.common.value.qual.DoubleVal",
+ "org.checkerframework.common.value.qual.IntRange",
+ "org.checkerframework.common.value.qual.IntVal",
+ "org.checkerframework.common.value.qual.MinLen",
+ "org.checkerframework.common.value.qual.PolyValue",
+ "org.checkerframework.common.value.qual.StringVal",
+ "org.checkerframework.common.value.qual.UnknownVal",
+ "org.checkerframework.framework.qual.PolyAll",
+ "org.checkerframework.framework.util.PurityUnqualified",
+ "org.eclipse.jdt.annotation.NonNull",
"org.eclipse.jdt.annotation.Nullable",
+ "org.jetbrains.annotations.NotNull",
"org.jetbrains.annotations.Nullable",
+ "org.springframework.lang.NonNull",
"org.springframework.lang.Nullable"
}));
}