Class NameMangler.JavaIdent
java.lang.Object
io.github.eutro.wasm2j.api.support.NameMangler.JavaIdent
- All Implemented Interfaces:
NameMangler
- Enclosing interface:
- NameMangler
A mangler which outputs valid Java identifiers.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.github.eutro.wasm2j.api.support.NameMangler
NameMangler.BanChars, NameMangler.IllegalSymbolPolicy, NameMangler.JavaIdent
-
Field Summary
Fields inherited from interface io.github.eutro.wasm2j.api.support.NameMangler
EMPTY_TOKEN, JVM_BANNED_CHARS
-
Constructor Summary
ConstructorDescriptionConstruct a Java identifier mangler. -
Method Summary
-
Constructor Details
-
JavaIdent
Construct a Java identifier mangler.- Parameters:
policy
- The policy for handling illegal characters.
-
-
Method Details
-
mangle
Description copied from interface:NameMangler
Mangle a string, so it becomes a valid name according to the rules of this mangler.- Specified by:
mangle
in interfaceNameMangler
- Parameters:
str
- The name to mangle- Returns:
- The mangled string.
-