类 StringSwitcher.Generator
java.lang.Object
cn.taketoday.bytecode.core.AbstractClassGenerator
cn.taketoday.bytecode.util.StringSwitcher.Generator
- 所有已实现的接口:
ClassGenerator
- 封闭类:
- StringSwitcher
-
嵌套类概要
从类继承的嵌套类/接口 cn.taketoday.bytecode.core.AbstractClassGenerator
AbstractClassGenerator.ClassLoaderData -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明create()Generate theStringSwitcher.protected ObjectfirstInstance(Class type) voidprotected ClassLoaderprotected ObjectnextInstance(Object instance) voidsetFixedInput(boolean fixedInput) Configure how unknown String keys will be handled.voidsetInts(int[] ints) Set the array of integer results.voidsetStrings(String[] strings) Set the array of recognized Strings.从类继承的方法 cn.taketoday.bytecode.core.AbstractClassGenerator
create, generate, getClassLoader, getClassName, getCurrent, getDefineClassStrategy, getNamingPolicy, getProtectionDomain, getStrategy, getUseCache, isAttemptLoad, setAttemptLoad, setClassLoader, setDefineClassStrategy, setNamePrefix, setNamingPolicy, setNeighbor, setStrategy, setUseCache, unwrapCachedValue, wrapCachedClass
-
构造器详细资料
-
Generator
public Generator()
-
-
方法详细资料
-
setStrings
Set the array of recognized Strings.- 参数:
strings- the array of String keys; must be the same length as the value array- 另请参阅:
-
setInts
public void setInts(int[] ints) Set the array of integer results.- 参数:
ints- the array of integer results; must be the same length as the key array- 另请参阅:
-
setFixedInput
public void setFixedInput(boolean fixedInput) Configure how unknown String keys will be handled.- 参数:
fixedInput- if false, an unknown key will be returned fromStringSwitcher.intValue(java.lang.String)as-1; if true, the result will be undefined, and the resulting code will be faster
-
getDefaultClassLoader
-
create
Generate theStringSwitcher. -
generateClass
- 抛出:
Exception
-
firstInstance
- 指定者:
firstInstance在类中AbstractClassGenerator
-
nextInstance
- 指定者:
nextInstance在类中AbstractClassGenerator
-