2006-11-22 17:38:46 +00:00
|
|
|
/*******************************************************************************
|
|
|
|
* Copyright (c) 2002 - 2006 IBM Corporation.
|
|
|
|
* All rights reserved. This program and the accompanying materials
|
|
|
|
* are made available under the terms of the Eclipse Public License v1.0
|
|
|
|
* which accompanies this distribution, and is available at
|
|
|
|
* http://www.eclipse.org/legal/epl-v10.html
|
|
|
|
*
|
|
|
|
* Contributors:
|
|
|
|
* IBM Corporation - initial API and implementation
|
|
|
|
*******************************************************************************/
|
|
|
|
package com.ibm.wala.ipa.callgraph.propagation;
|
|
|
|
|
2007-07-05 03:04:34 +00:00
|
|
|
import com.ibm.wala.cfg.ControlFlowGraph;
|
2006-11-22 17:38:46 +00:00
|
|
|
import com.ibm.wala.ipa.callgraph.CGNode;
|
|
|
|
import com.ibm.wala.ipa.callgraph.propagation.rta.RTAContextInterpreter;
|
|
|
|
import com.ibm.wala.ssa.DefUse;
|
|
|
|
import com.ibm.wala.ssa.IR;
|
|
|
|
import com.ibm.wala.util.warnings.WarningSet;
|
|
|
|
|
|
|
|
/**
|
2007-07-05 03:04:34 +00:00
|
|
|
*
|
|
|
|
* An object that provides an interface to local method information needed for
|
|
|
|
* CFA.
|
2006-11-22 17:38:46 +00:00
|
|
|
*
|
|
|
|
* @author sfink
|
|
|
|
*/
|
2007-07-05 03:04:34 +00:00
|
|
|
public interface SSAContextInterpreter extends RTAContextInterpreter {
|
2006-11-22 17:38:46 +00:00
|
|
|
|
|
|
|
/**
|
2007-07-05 03:04:34 +00:00
|
|
|
* @return the IR that models the method context, or null if it's an
|
|
|
|
* unmodelled native method
|
2006-11-22 17:38:46 +00:00
|
|
|
*/
|
|
|
|
public IR getIR(CGNode node, WarningSet warnings);
|
|
|
|
|
2007-07-05 03:04:34 +00:00
|
|
|
/**
|
|
|
|
* @return DefUse for the IR that models the method context, or null if it's
|
|
|
|
* an unmodelled native method
|
|
|
|
*/
|
2006-11-22 17:38:46 +00:00
|
|
|
public DefUse getDU(CGNode node, WarningSet warnings);
|
2007-07-05 03:04:34 +00:00
|
|
|
|
2006-11-22 17:38:46 +00:00
|
|
|
/**
|
2007-07-05 03:04:34 +00:00
|
|
|
* @return the number of the statements in the IR, or -1 if it's an unmodelled
|
|
|
|
* native method.
|
2006-11-22 17:38:46 +00:00
|
|
|
*/
|
|
|
|
public int getNumberOfStatements(CGNode node, WarningSet warnings);
|
|
|
|
|
2007-07-05 03:04:34 +00:00
|
|
|
public ControlFlowGraph getCFG(CGNode n, WarningSet warnings);
|
|
|
|
|
2006-11-22 17:38:46 +00:00
|
|
|
}
|