本文整理汇总了Java中org.apache.bcel.classfile.LocalVariableTypeTable类的典型用法代码示例。如果您正苦于以下问题:Java LocalVariableTypeTable类的具体用法?Java LocalVariableTypeTable怎么用?Java LocalVariableTypeTable使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
LocalVariableTypeTable类属于org.apache.bcel.classfile包,在下文中一共展示了LocalVariableTypeTable类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: TypeAnalysis
import org.apache.bcel.classfile.LocalVariableTypeTable; //导入依赖的package包/类
/**
* Constructor.
*
* @param method
* TODO
* @param methodGen
* the MethodGen whose CFG we'll be analyzing
* @param cfg
* the control flow graph
* @param dfs
* DepthFirstSearch of the method
* @param typeMerger
* object to merge types
* @param visitor
* a TypeFrameModelingVisitor to use to model the effect of
* instructions
* @param lookupFailureCallback
* lookup failure callback
* @param exceptionSetFactory
* factory for creating ExceptionSet objects
*/
public TypeAnalysis(Method method, MethodGen methodGen, CFG cfg, DepthFirstSearch dfs, TypeMerger typeMerger,
TypeFrameModelingVisitor visitor, RepositoryLookupFailureCallback lookupFailureCallback,
ExceptionSetFactory exceptionSetFactory) {
super(dfs);
this.method = method;
Code code = method.getCode();
if (code == null)
throw new IllegalArgumentException(method.getName() + " has no code");
for (Attribute a : code.getAttributes()) {
if (a instanceof LocalVariableTypeTable)
visitor.setLocalTypeTable((LocalVariableTypeTable) a);
}
this.methodGen = methodGen;
this.cfg = cfg;
this.typeMerger = typeMerger;
this.visitor = visitor;
this.thrownExceptionSetMap = new HashMap<BasicBlock, CachedExceptionSet>();
this.lookupFailureCallback = lookupFailureCallback;
this.exceptionSetFactory = exceptionSetFactory;
this.instanceOfCheckMap = new HashMap<BasicBlock, InstanceOfCheck>();
if (DEBUG) {
System.out.println("\n\nAnalyzing " + methodGen);
}
}
示例2: TypeAnalysis
import org.apache.bcel.classfile.LocalVariableTypeTable; //导入依赖的package包/类
/**
* Constructor.
*
* @param method
* TODO
* @param methodGen
* the MethodGen whose CFG we'll be analyzing
* @param cfg
* the control flow graph
* @param dfs
* DepthFirstSearch of the method
* @param typeMerger
* object to merge types
* @param visitor
* a TypeFrameModelingVisitor to use to model the effect of
* instructions
* @param lookupFailureCallback
* lookup failure callback
* @param exceptionSetFactory
* factory for creating ExceptionSet objects
*/
public TypeAnalysis(Method method, MethodGen methodGen, CFG cfg, DepthFirstSearch dfs, TypeMerger typeMerger,
TypeFrameModelingVisitor visitor, RepositoryLookupFailureCallback lookupFailureCallback,
ExceptionSetFactory exceptionSetFactory) {
super(dfs);
this.method = method;
Code code = method.getCode();
if (code == null)
throw new IllegalArgumentException(method.getName() + " has no code");
for (Attribute a : code.getAttributes()) {
if (a instanceof LocalVariableTypeTable)
visitor.setLocalTypeTable((LocalVariableTypeTable) a);
}
this.methodGen = methodGen;
this.cfg = cfg;
this.typeMerger = typeMerger;
this.visitor = visitor;
this.thrownExceptionSetMap = new HashMap<BasicBlock, CachedExceptionSet>();
this.lookupFailureCallback = lookupFailureCallback;
this.exceptionSetFactory = exceptionSetFactory;
this.instanceOfCheckMap = new HashMap<BasicBlock, InstanceOfCheck>();
if (DEBUG) {
System.out.println("\n\nAnalyzing " + methodGen);
}
}
示例3: setLocalTypeTable
import org.apache.bcel.classfile.LocalVariableTypeTable; //导入依赖的package包/类
public void setLocalTypeTable(LocalVariableTypeTable localTypeTable) {
this.localTypeTable = localTypeTable;
if (localTypeTable == null)
genericLocalVariables = null;
else {
genericLocalVariables = new BitSet();
for(LocalVariable lv : localTypeTable.getLocalVariableTypeTable()) {
if (lv.getSignature().indexOf('<') > 0)
genericLocalVariables.set(lv.getIndex());
}
}
}
示例4: visit
import org.apache.bcel.classfile.LocalVariableTypeTable; //导入依赖的package包/类
public void visit(LocalVariableTypeTable obj) {
// must explicitly override to get functionality
}
示例5: visitLocalVariableTypeTable
import org.apache.bcel.classfile.LocalVariableTypeTable; //导入依赖的package包/类
public void visitLocalVariableTypeTable(LocalVariableTypeTable obj) {
visit(obj);
}