Class NullAwayExtension

java.lang.Object
net.ltgt.gradle.nullaway.NullAwayExtension

public abstract class NullAwayExtension extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    abstract org.gradle.api.provider.ListProperty<String>
    The list of packages that should be considered properly annotated according to the NullAway convention.
    abstract org.gradle.api.provider.Property<Boolean>
    Convenience option that enables the experimental HandleWildcardGenerics, JSpecifyJDKModels, and WarnOnGenericInferenceFailure features.
    abstract org.gradle.api.provider.Property<Boolean>
    If set to true, enables new checks based on JSpecify (like checks for generic types)
    abstract org.gradle.api.provider.Property<Boolean>
    Indicates that the getAnnotatedPackages() flag has been deliberately omitted, and that NullAway can proceed with only treating @NullMarked code as annotated, in accordance with the JSpecify specification.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • NullAwayExtension

      public NullAwayExtension()
  • Method Details

    • getOnlyNullMarked

      public abstract org.gradle.api.provider.Property<Boolean> getOnlyNullMarked()
      Indicates that the getAnnotatedPackages() flag has been deliberately omitted, and that NullAway can proceed with only treating @NullMarked code as annotated, in accordance with the JSpecify specification.
    • getAnnotatedPackages

      public abstract org.gradle.api.provider.ListProperty<String> getAnnotatedPackages()
      The list of packages that should be considered properly annotated according to the NullAway convention.
    • getJspecifyMode

      public abstract org.gradle.api.provider.Property<Boolean> getJspecifyMode()
      If set to true, enables new checks based on JSpecify (like checks for generic types)
    • getJspecifyExperimental

      public abstract org.gradle.api.provider.Property<Boolean> getJspecifyExperimental()
      Convenience option that enables the experimental HandleWildcardGenerics, JSpecifyJDKModels, and WarnOnGenericInferenceFailure features. This option must be used with jspecifyMode = true.