• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java LoadInstruction类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.apache.bcel.generic.LoadInstruction的典型用法代码示例。如果您正苦于以下问题:Java LoadInstruction类的具体用法?Java LoadInstruction怎么用?Java LoadInstruction使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



LoadInstruction类属于org.apache.bcel.generic包,在下文中一共展示了LoadInstruction类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: getLoadInstruction

import org.apache.bcel.generic.LoadInstruction; //导入依赖的package包/类
private InstructionHandle getLoadInstruction(InstructionList il, 
    SpawnableCall spawnableCall) throws SyncInsertionProposalFailure {

InstructionHandle ih = spawnableCall.getInvokeInstruction();
while ((ih = ih.getNext()) != null) {
    try {
	LoadInstruction loadInstruction = 
	    (LoadInstruction) (ih.getInstruction());
	if (spawnableCall.storesIn(loadInstruction.getIndex(), ih)) {
	    return ih;
		}
    }
    catch (ClassCastException e) {
    }
}
throw new SyncInsertionProposalFailure();
   }
 
开发者ID:pieterhijma,项目名称:cashmere,代码行数:18,代码来源:EarliestLoad.java


示例2: handleLoadInstruction

import org.apache.bcel.generic.LoadInstruction; //导入依赖的package包/类
@Override
public void handleLoadInstruction(LoadInstruction obj) {
    int numProduced = obj.produceStack(cpg);
    if (numProduced == Constants.UNPREDICTABLE) {
        throw new InvalidBytecodeException("Unpredictable stack production");
    }
    int index = obj.getIndex() + numProduced;
    while (numProduced-- > 0) {
        Taint value = getFrame().getValue(--index);
        assert value.hasValidVariableIndex() : "index not set in " + methodDescriptor;
        assert index == value.getVariableIndex() : "bad index in " + methodDescriptor;
        getFrame().pushValue(new Taint(value));
    }
}
 
开发者ID:blackarbiter,项目名称:Android_Code_Arbiter,代码行数:15,代码来源:TaintFrameModelingVisitor.java


示例3: visitLoadInstruction

import org.apache.bcel.generic.LoadInstruction; //导入依赖的package包/类
public void visitLoadInstruction(LoadInstruction l) {
	// log.log(" visit load", Project.MSG_DEBUG);
	Type t = l.getType(poolGen);
	log.log("         instr(loadinstr)=" + t, Project.MSG_DEBUG);
	String type = t.toString();

	design.checkClass(type);
}
 
开发者ID:cniweb,项目名称:ant-contrib,代码行数:9,代码来源:InstructionVisitor.java


示例4: isLoad

import org.apache.bcel.generic.LoadInstruction; //导入依赖的package包/类
private boolean isLoad(Location location) {
	Instruction ins = location.getHandle().getInstruction();
	return (ins instanceof LoadInstruction) || (ins instanceof IINC);
}
 
开发者ID:parabuild-ci,项目名称:parabuild-ci,代码行数:5,代码来源:FindDeadLocalStores.java


示例5: visitLoadInstruction

import org.apache.bcel.generic.LoadInstruction; //导入依赖的package包/类
public void visitLoadInstruction(LoadInstruction aInstruction)
{
    mLocalVariableBitSet.set(aInstruction.getIndex());
}
 
开发者ID:parabuild-ci,项目名称:parabuild-ci,代码行数:5,代码来源:UnreadVariableCheck.java


示例6: isLocalLoad

import org.apache.bcel.generic.LoadInstruction; //导入依赖的package包/类
static boolean isLocalLoad(Instruction ins) {
    return (ins instanceof LoadInstruction);
}
 
开发者ID:pieterhijma,项目名称:cashmere,代码行数:4,代码来源:Cashmerec.java


示例7: instructionLoadsTo

import org.apache.bcel.generic.LoadInstruction; //导入依赖的package包/类
/** Tests whether an instruction loads to a local variable with a certain
    * index.
    *
    * When the load is used for an array store or a putfield, the result will
    * be false. It
    * uses {@link #isUsedForArrayStore(InstructionHandle)} and {@link
    * #isUsedForPutField(InstructionHandle)}.
    *
    * @param ih The instruction that is tested to load to a local variable
    * index.
    * @param localVarIndex The local variable index to which the instruction
    * may load
    *
    * @return true if the instruction loads to the local variable index, false
    * otherwise. 
    *
    * @see #isUsedForArrayStore(InstructionHandle)
    * @see #isUsedForPutField(InstructionHandle)
    */
   public boolean instructionLoadsTo(InstructionHandle ih, int localVarIndex) {
try {
    LoadInstruction loadInstruction = (LoadInstruction) (ih.getInstruction());
    return loadInstruction.getIndex() == localVarIndex && 
        !isUsedForArrayLength(ih) &&
	!isUsedForArrayStore(ih) && !isUsedForPutField(ih);
}
catch(ClassCastException e) {
    return false;
}
   }
 
开发者ID:pieterhijma,项目名称:cashmere,代码行数:31,代码来源:MethodGen.java


示例8: isLoad

import org.apache.bcel.generic.LoadInstruction; //导入依赖的package包/类
/**
 * Is instruction at given location a load?
 * 
 * @param location
 *            the location
 * @return true if instruction at given location is a load, false if not
 */
private boolean isLoad(Location location) {
    Instruction ins = location.getHandle().getInstruction();
    return (ins instanceof LoadInstruction) || (ins instanceof IINC);
}
 
开发者ID:ytus,项目名称:findbugs-all-the-bugs,代码行数:12,代码来源:FindDeadLocalStores.java


示例9: isLoad

import org.apache.bcel.generic.LoadInstruction; //导入依赖的package包/类
/**
 * Is instruction at given location a load?
 *
 * @param location
 *            the location
 * @return true if instruction at given location is a load, false if not
 */
private boolean isLoad(Location location) {
    Instruction ins = location.getHandle().getInstruction();
    return (ins instanceof LoadInstruction) || (ins instanceof IINC);
}
 
开发者ID:OpenNTF,项目名称:FindBug-for-Domino-Designer,代码行数:12,代码来源:FindDeadLocalStores.java



注:本文中的org.apache.bcel.generic.LoadInstruction类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java DLFolderConstants类代码示例发布时间:2022-05-22
下一篇:
Java Gradle类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap