Enum Class ExecutionMode

java.lang.Object
java.lang.Enum<ExecutionMode>
fr.ens.biologie.genomique.eoulsan.annotations.ExecutionMode
All Implemented Interfaces:
Serializable, Comparable<ExecutionMode>, Constable

public enum ExecutionMode extends Enum<ExecutionMode>
This class define an enum for the execution mode of Eoulsan.
Since:
2.0
Author:
Laurent Jourdren
  • Enum Constant Details

  • Method Details

    • values

      public static ExecutionMode[] 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 ExecutionMode 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
    • getAnnotationClass

      public Class<? extends Annotation> getAnnotationClass()
      Get the Eoulsan annotation class that corresponds to the Eoulsan mode.
      Returns:
      an annotation class
    • isLocalCompatible

      public boolean isLocalCompatible()
      Test if the excution mode is compatible with local mode.
      Returns:
      true if the mode is compatible with local mode
    • isHadoopCompatible

      public boolean isHadoopCompatible()
      Test if the execution mode is compatible with Hadoop mode.
      Returns:
      true if the mode is compatible with Hadoop mode
    • accept

      public static boolean accept(Class<?> clazz, boolean hadoopMode)
      Check that annotation of a class is compatible with the Eoulsan mode (local or Hadoop).
      Parameters:
      clazz - class to test
      hadoopMode - Hadoop mode
      Returns:
      true if the annotation of the class is compatible with the Eoulsan mode
    • getExecutionMode

      public static ExecutionMode getExecutionMode(Class<?> annotationClazz)
      Get the execution mode related to an annotation class.
      Parameters:
      annotationClazz - class to test
      Returns:
      an EoulsanMode object