Enum Class WeightingType

java.lang.Object
java.lang.Enum<WeightingType>
com.xinapse.image.template.WeightingType
All Implemented Interfaces:
Serializable, Comparable<WeightingType>, Constable

public enum WeightingType extends Enum<WeightingType>
An enumeration of MR image intensity weighting types.
  • Enum Constant Details

    • T1

      public static final WeightingType T1
      An image weighting type of T1-weighted.
    • T2

      public static final WeightingType T2
      An image weighting type of T2-weighted.
    • PD

      public static final WeightingType PD
      An image weighting type of proton density weighted.
  • Field Details

    • DEFAULT

      public static final WeightingType DEFAULT
      The default WeightingType for applications.
    • OPTION

      public static final org.apache.commons.cli.Option OPTION
      The Option for selecting a WeightingType.
  • Method Details

    • values

      public static WeightingType[] 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 WeightingType 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
    • getInstance

      public static WeightingType getInstance(String typeString) throws InvalidArgumentException
      Returns a WeightingType Object corresponding to the supplied String.
      Parameters:
      typeString - a String which indicates the weighting type.
      Returns:
      a WeightingType Object corresponding to the supplied String.
      Throws:
      InvalidArgumentException - if the supplied String does not correspond to any of the WeightingTypes.
    • getDescription

      public String getDescription()
      Returns a string describing this image weighting type.
      Returns:
      a string describing this image weighting type.
    • getFullDescription

      public String getFullDescription()
      Returns a "full" description of this WeightingType.
      Returns:
      a "full" description of this WeightingType.
    • getPreferredWeightingType

      public static WeightingType getPreferredWeightingType(Preferences prefs)
      Gets the WeightingType set in the preferences.
      Parameters:
      prefs - the preferences.
      Returns:
      the WeightingType set in the preferences.
    • savePreferredWeightingType

      public static void savePreferredWeightingType(Preferences prefs, WeightingType type)
      Saves the WeightingType to the preferences.
      Parameters:
      type - the WeightingType.
      prefs - the preferences.
    • main

      public static void main(String[] args)
      Runs the self-test for WeightingType.
      Parameters:
      args - ignored.