Package org.eclipse.jdt.core.dom

# Class ModuleModifier.ModuleModifierKeyword

java.lang.Object
org.eclipse.jdt.core.dom.ModuleModifier.ModuleModifierKeyword

Enclosing class:
  `ModuleModifier`

public static class ModuleModifier.ModuleModifierKeyword extends Object
Module Modifier keywords (typesafe enumeration).

## Field Summary

Fields
Modifier and Type
Field
Description
`static final ModuleModifier.ModuleModifierKeyword`
`STATIC_KEYWORD`
"static" modifier with flag value `ModuleModifier.STATIC_PHASE`.
`static final ModuleModifier.ModuleModifierKeyword`
`TRANSITIVE_KEYWORD`
"transitive" modifier with flag value `ModuleModifier.TRANSITIVE`.

## Method Summary

Modifier and Type
Method
Description
`static ModuleModifier.ModuleModifierKeyword`
`fromFlagValue(int flagValue)`
Returns the module modifier corresponding to the given single-bit flag value, or `null` if none or if more than one bit is set.
`int`
`toFlagValue()`
Returns the module modifier flag value corresponding to this module modifier keyword.
`static ModuleModifier.ModuleModifierKeyword`
`toKeyword(String keyword)`
Returns the module modifier corresponding to the given string, or `null` if none.
`String`
`toString()`
Returns the keyword for the module modifier.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Field Details

### STATIC_KEYWORD

public static final ModuleModifier.ModuleModifierKeyword STATIC_KEYWORD
"static" modifier with flag value `ModuleModifier.STATIC_PHASE`.

### TRANSITIVE_KEYWORD

public static final ModuleModifier.ModuleModifierKeyword TRANSITIVE_KEYWORD
"transitive" modifier with flag value `ModuleModifier.TRANSITIVE`.

## Method Details

### fromFlagValue

public static ModuleModifier.ModuleModifierKeyword fromFlagValue(int flagValue)
Returns the module modifier corresponding to the given single-bit flag value, or `null` if none or if more than one bit is set.

`fromFlagValue` is the converse of `toFlagValue`: that is, `ModuleModifierKind.fromFlagValue(k.toFlagValue()) == k` for all module modifier keywords `k`.

Parameters:
  `flagValue` - the single-bit flag value for the module modifier
Returns:
  the module modifier keyword, or `null` if none
See Also:
  - `toFlagValue()`

### toKeyword

public static ModuleModifier.ModuleModifierKeyword toKeyword(String keyword)
Returns the module modifier corresponding to the given string, or `null` if none.

`toKeyword` is the converse of `toString`: that is, `ModuleModifierKind.toKeyword(k.toString()) == k` for all module modifier keywords `k`.

Parameters:
  `keyword` - the lowercase string name for the module modifier
Returns:
  the module modifier keyword, or `null` if none
See Also:
  - `toString()`

### toFlagValue

public int toFlagValue()
Returns the module modifier flag value corresponding to this module modifier keyword. These flag values are as described in the Java Virtual Machine Specification.

Returns:
  one of the `ModuleModifier` constants
See Also:
  - `fromFlagValue(int)`

### toString

public String toString()
Returns the keyword for the module modifier.

Overrides:
  `toString` in class `Object`
Returns:
  the keyword for the module modifier
See Also:
  - `toKeyword(String)`