|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
E
- the enumeration constant describing all possible flags.public interface IFlagGroup<E extends Enum<E> & IFlag>
A flag group.
This interface represents a flag group. The value of a flag group is a single integer value,
which can be accessed using IGroup.longValue()
. How this value can be interpreted, depends on the
available flags of the flag group. Depending on the current protocol-version of the flag group,
different flags may be available with different flag values.
In a flag group multiple flags can be active at the same time.
See IGroup.longValue()
for the current value of the group.
See IGroup.getGroupClass()
for the enum class defining all possible flags.
See getSupportedFlags()
for all flags that are available for the current protocol version.
See getActiveFlags()
for all currently active flags.
To test if a specific flag is currently active, isSet(Enum)
can be used.
// a flag group IProgramFlags flags = recording.getProgramFlags(); // testing if a flag is set boolean hasBookmark = flags.isSet(Flags.FL_BOOKMARK); if(hasBookmark) { // do something ... }
Method Summary | |
---|---|
EnumSet<E> |
getActiveFlags()
Gets all currently active flags of this group. |
EnumMap<E,Boolean> |
getFlagMap()
Gets a map with all flags and their isSet status. |
EnumSet<E> |
getInactiveFlags()
Gets all currently inactive flags of this group. |
EnumSet<E> |
getSupportedFlags()
Gets all possible flags of this flag group. |
boolean |
isSet(E flag)
Checks if the given flag is actually set. |
Methods inherited from interface org.jmythapi.protocol.response.IGroup |
---|
getGroupClass, longValue |
Methods inherited from interface org.jmythapi.IVersionable |
---|
getVersionNr |
Method Detail |
---|
EnumSet<E> getSupportedFlags()
EnumSet<E> getActiveFlags()
EnumSet<E> getInactiveFlags()
EnumMap<E,Boolean> getFlagMap()
boolean isSet(E flag)
flag
- the flag to check
true
if the flag is currently set.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |