Enum Class Discovery

java.lang.Object
java.lang.Enum<Discovery>
net.bytebuddy.build.maven.Discovery
All Implemented Interfaces:
Serializable, Comparable<Discovery>, Constable

public enum Discovery extends Enum<Discovery>
Determines how and if plugins are discovered.
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    Attempts discovery of plugins even if they are explicitly registered.
    Only discovers plugins if no plugin was explicitly registered.
    Does never discover plugins.
    Attempts discovery of plugins but does not discover plugins that are explicitly registered.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final boolean
    true if explicit configurations should be recorded.
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    private
    Discovery(boolean recordConfiguration)
    Creates a new discovery configuration.
  • Method Summary

    Modifier and Type
    Method
    Description
    protected abstract boolean
    Determines if plugins should be discovered from the class path.
    protected boolean
    Returns true if explicit configurations should be recorded.
    static Discovery
    Returns the enum constant of this class with the specified name.
    static Discovery[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • ALL

      public static final Discovery ALL
      Attempts discovery of plugins even if they are explicitly registered.
    • UNIQUE

      public static final Discovery UNIQUE
      Attempts discovery of plugins but does not discover plugins that are explicitly registered.
    • EMPTY

      public static final Discovery EMPTY
      Only discovers plugins if no plugin was explicitly registered. This is the default configuration.
    • NONE

      public static final Discovery NONE
      Does never discover plugins.
  • Field Details

    • recordConfiguration

      private final boolean recordConfiguration
      true if explicit configurations should be recorded.
  • Constructor Details

    • Discovery

      private Discovery(boolean recordConfiguration)
      Creates a new discovery configuration.
      Parameters:
      recordConfiguration - true if explicit configurations should be recorded.
  • Method Details

    • values

      public static Discovery[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static Discovery valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • isRecordConfiguration

      protected boolean isRecordConfiguration()
      Returns true if explicit configurations should be recorded.
      Returns:
      true if explicit configurations should be recorded.
    • isDiscover

      protected abstract boolean isDiscover(List<ByteBuddyMojo.Transformer> transformers)
      Determines if plugins should be discovered from the class path.
      Parameters:
      transformers - The configured transformers.
      Returns:
      true if plugins should be discovered from the class path.