Package org.gnome.glib
Enum Class OptionFlags
- All Implemented Interfaces:
Serializable,Comparable<OptionFlags>,Constable,Enumeration
@Generated("io.github.jwharm.JavaGI")
public enum OptionFlags
extends Enum<OptionFlags>
implements Enumeration
Flags which modify individual options.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThis flag marks the option as deprecated in the--help.For options of theOptionArg.CALLBACKkind, this flag indicates that the argument should be passed to the callback in the GLib filename encoding rather than UTF-8.The option doesn't appear in--helpoutput.The option appears in the main section of the--helpoutput, even if it is defined in a group.For options of theOptionArg.CALLBACKkind, this flag indicates that the callback does not take any argument (like aOptionArg.NONEoption).This flag turns off the automatic conflict resolution which prefixes long option names withgroupname-if there is a conflict.No flags.For options of theOptionArg.CALLBACKkind, this flag indicates that the argument supply is optional.For options of theOptionArg.NONEkind, this flag indicates that the sense of the option is reversed. -
Method Summary
Modifier and TypeMethodDescriptionintgetValue()Get the numeric value of this enumstatic Set<OptionFlags> of(int flags) Create a newEnumSet<OptionFlags>for the provided bitfieldstatic Set<OptionFlags> of(MemorySegment address) Create a newEnumSet<OptionFlags>for the bitfield in the provided memory address.static OptionFlagsReturns the enum constant of this class with the specified name.static OptionFlags[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
NONE
-
HIDDEN
The option doesn't appear in--helpoutput. -
IN_MAIN
The option appears in the main section of the--helpoutput, even if it is defined in a group. -
REVERSE
For options of theOptionArg.NONEkind, this flag indicates that the sense of the option is reversed. i.e.falsewill be stored into the argument rather thantrue. -
NO_ARG
For options of theOptionArg.CALLBACKkind, this flag indicates that the callback does not take any argument (like aOptionArg.NONEoption). Since 2.8 -
FILENAME
For options of theOptionArg.CALLBACKkind, this flag indicates that the argument should be passed to the callback in the GLib filename encoding rather than UTF-8. Since 2.8 -
OPTIONAL_ARG
For options of theOptionArg.CALLBACKkind, this flag indicates that the argument supply is optional. If no argument is given then data ofGOptionParseFuncwill be set to NULL. Since 2.8 -
NOALIAS
This flag turns off the automatic conflict resolution which prefixes long option names withgroupname-if there is a conflict. This option should only be used in situations where aliasing is necessary to model some legacy commandline interface. It is not safe to use this option, unless all option groups are under your direct control. Since 2.8. -
DEPRECATED
This flag marks the option as deprecated in the--help.You should update the description of the option to describe what the user should do in response to the deprecation, for instance: remove the option, or replace it with another one.
- Since:
- 2.84
-
-
Method Details
-
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
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 nameNullPointerException- if the argument is null
-
getValue
public int getValue()Get the numeric value of this enum- Specified by:
getValuein interfaceEnumeration- Returns:
- the enum value
-
of
Create a newEnumSet<OptionFlags>for the provided bitfield- Parameters:
flags- the OptionFlags bitfield- Returns:
- the EnumSet for the provided bitfield
-
of
Create a newEnumSet<OptionFlags>for the bitfield in the provided memory address.- Parameters:
address- the memory address holding a bitfield value- Returns:
- the EnumSet for the bitfield in the provided memory address
-