com.flexive.shared.structure
Enum GroupMode

java.lang.Object
  extended by java.lang.Enum<GroupMode>
      extended by com.flexive.shared.structure.GroupMode
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<GroupMode>

public enum GroupMode
extends java.lang.Enum<GroupMode>

Mode how groups act (one-of or any-of)

Author:
Markus Plesser (markus.plesser@flexive.com), UCS - unique computing solutions gmbh (http://www.ucs.at)

Enum Constant Summary
AnyOf
          Any of the groups children may be present, honoring their regular indices
OneOf
          Only one of the groups children may be present, honoring their regular indices.
 
Method Summary
static GroupMode getById(int id)
          Get a GroupMode by its id
 int getId()
          Getter for the id
static GroupMode valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static GroupMode[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

OneOf

public static final GroupMode OneOf
Only one of the groups children may be present, honoring their regular indices. This mode only makes sense if all subgroups/properties are optional!


AnyOf

public static final GroupMode AnyOf
Any of the groups children may be present, honoring their regular indices

Method Detail

values

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

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

valueOf

public static GroupMode valueOf(java.lang.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:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

getId

public int getId()
Getter for the id

Returns:
id

getById

public static GroupMode getById(int id)
                         throws FxNotFoundException
Get a GroupMode by its id

Parameters:
id - internal id
Returns:
GroupMode
Throws:
FxNotFoundException - on errors