com.ibm.wala.cast.js.ipa.callgraph
Class Util

java.lang.Object
  extended by com.ibm.wala.cast.ipa.callgraph.Util
      extended by com.ibm.wala.cast.js.ipa.callgraph.Util
Direct Known Subclasses:
Util

public class Util
extends Util


Field Summary
protected static JavaScriptTranslatorFactory translatorFactory
          the translator factory to be used for analysis TODO: pass the factory where needed instead of using a global?
 
Constructor Summary
Util()
           
 
Method Summary
static java.util.Collection getNodes(CallGraph CG, java.lang.String funName)
           
static JavaScriptTranslatorFactory getTranslatorFactory()
           
static java.util.Set<java.lang.String> loadAdditionalFile(IClassHierarchy cha, JavaScriptLoader cl, java.lang.String fileName, java.net.URL url, java.lang.String file)
           
static IClassHierarchy makeHierarchy(AnalysisScope scope, ClassLoaderFactory loaders)
           
static JavaScriptLoaderFactory makeLoaders()
           
static AnalysisOptions makeOptions(AnalysisScope scope, IClassHierarchy cha, java.lang.Iterable<Entrypoint> roots)
           
static java.lang.Iterable<Entrypoint> makeScriptRoots(IClassHierarchy cha)
           
static void setTranslatorFactory(JavaScriptTranslatorFactory translatorFactory)
          Set up the translator factory.
 
Methods inherited from class com.ibm.wala.cast.ipa.callgraph.Util
dumpCG, handleFileNames, makeCache, makeScope, makeScope, makeScope, makeSourceModule, makeSourceModule
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

translatorFactory

protected static JavaScriptTranslatorFactory translatorFactory
the translator factory to be used for analysis TODO: pass the factory where needed instead of using a global?

Constructor Detail

Util

public Util()
Method Detail

setTranslatorFactory

public static void setTranslatorFactory(JavaScriptTranslatorFactory translatorFactory)
Set up the translator factory. This method should be called before invoking makeLoaders().


getTranslatorFactory

public static JavaScriptTranslatorFactory getTranslatorFactory()

makeOptions

public static AnalysisOptions makeOptions(AnalysisScope scope,
                                          IClassHierarchy cha,
                                          java.lang.Iterable<Entrypoint> roots)

makeLoaders

public static JavaScriptLoaderFactory makeLoaders()

makeHierarchy

public static IClassHierarchy makeHierarchy(AnalysisScope scope,
                                            ClassLoaderFactory loaders)
                                     throws ClassHierarchyException
Throws:
ClassHierarchyException

makeScriptRoots

public static java.lang.Iterable<Entrypoint> makeScriptRoots(IClassHierarchy cha)

getNodes

public static java.util.Collection getNodes(CallGraph CG,
                                            java.lang.String funName)

loadAdditionalFile

public static java.util.Set<java.lang.String> loadAdditionalFile(IClassHierarchy cha,
                                                                 JavaScriptLoader cl,
                                                                 java.lang.String fileName,
                                                                 java.net.URL url,
                                                                 java.lang.String file)
                                                          throws java.io.IOException
Parameters:
cha -
cl -
fileName -
url -
file -
Returns:
The set of class names that where defined in the CHA as a result loading process.
Throws:
java.io.IOException