bibliothek.gui.dock.facile.mode.status
Enum ExtendedModeEnablement.Availability

java.lang.Object
  extended by java.lang.Enum<ExtendedModeEnablement.Availability>
      extended by bibliothek.gui.dock.facile.mode.status.ExtendedModeEnablement.Availability
All Implemented Interfaces:
Serializable, Comparable<ExtendedModeEnablement.Availability>
Enclosing interface:
ExtendedModeEnablement

public static enum ExtendedModeEnablement.Availability
extends Enum<ExtendedModeEnablement.Availability>

A measurement of how available a certain mode is. Is several ExtendedModeEnablement.Availabilitys are present, the first one of this list wins:

  1. STRONG_FORBIDDEN
  2. STRONG_AVAILABLE
  3. WEAK_FORBIDDEN
  4. WEAK_AVAILABLE
  5. UNCERTAIN

Author:
Benjamin Sigg

Enum Constant Summary
STRONG_AVAILABLE
          the mode is most certainly available
STRONG_FORBIDDEN
          the mode is not available
UNCERTAIN
          the strategy cannot decide, some other code will make the decision
WEAK_AVAILABLE
          the mode is probably available
WEAK_FORBIDDEN
          the mode is probably not available
 
Method Summary
 boolean isAvailable()
          Tells whether this ExtendedModeEnablement.Availability means "available" or "forbidden".
 ExtendedModeEnablement.Availability strongest(ExtendedModeEnablement.Availability other)
          Gets the strongest ExtendedModeEnablement.Availability of this and other.
static ExtendedModeEnablement.Availability valueOf(String name)
          Returns the enum constant of this type with the specified name.
static ExtendedModeEnablement.Availability[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

STRONG_AVAILABLE

public static final ExtendedModeEnablement.Availability STRONG_AVAILABLE
the mode is most certainly available


WEAK_AVAILABLE

public static final ExtendedModeEnablement.Availability WEAK_AVAILABLE
the mode is probably available


UNCERTAIN

public static final ExtendedModeEnablement.Availability UNCERTAIN
the strategy cannot decide, some other code will make the decision


WEAK_FORBIDDEN

public static final ExtendedModeEnablement.Availability WEAK_FORBIDDEN
the mode is probably not available


STRONG_FORBIDDEN

public static final ExtendedModeEnablement.Availability STRONG_FORBIDDEN
the mode is not available

Method Detail

values

public static final ExtendedModeEnablement.Availability[] values()
Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants as follows:
for(ExtendedModeEnablement.Availability c : ExtendedModeEnablement.Availability.values())
        System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they're declared

valueOf

public static ExtendedModeEnablement.Availability valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified name

isAvailable

public boolean isAvailable()
Tells whether this ExtendedModeEnablement.Availability means "available" or "forbidden".

Returns:
true if this means "available".

strongest

public ExtendedModeEnablement.Availability strongest(ExtendedModeEnablement.Availability other)
Gets the strongest ExtendedModeEnablement.Availability of this and other.

Parameters:
other - some other ExtendedModeEnablement.Availability
Returns:
the stronger of this and other