coins.aflow.util
Class SelfCollectingResults

java.lang.Object
  extended byjava.util.AbstractMap
      extended byjava.util.HashMap
          extended bycoins.aflow.util.SelfCollectingResults
All Implemented Interfaces:
java.lang.Cloneable, java.util.Map, java.io.Serializable
Direct Known Subclasses:
FlowResults

public class SelfCollectingResults
extends java.util.HashMap

Title: SelfCollectingResults

Description: Map class that responds to the query ("get") by, if the requested key is not found, calling methods that collects the info (value for the key). This class extends HashMap, so all the methods of HashMap are available. The keys of this map are the the name of the information, and optionally (but almost always) other information that seems convenient if the user has the direct access (rather than through the table that the value of the map could have otherwise hold). The set of keys present in the instance of this map can be thought of as the current level of progress of analysis this map represents.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class java.util.HashMap
 
Nested classes inherited from class java.util.AbstractMap
 
Field Summary
 Poset fAnalDependenceGraph
           
 java.util.Map fComrades
           
protected static RegisterAnalClasses regClasses
           
 
Fields inherited from class java.util.HashMap
 
Fields inherited from class java.util.AbstractMap
 
Constructor Summary
SelfCollectingResults()
           
 
Method Summary
 boolean containsKey(java.lang.String pAnal)
           
 boolean containsKey(java.lang.String pAnal, java.lang.Object pObj)
           
 boolean containsKey(java.lang.String pAnal, java.lang.Object pObj, java.lang.Object pObj0)
           
 void find(java.lang.String pAnal)
           
 void find(java.lang.String pAnal, java.lang.Object pObj)
           
 void find(java.lang.String pAnal, java.lang.Object pObj, java.lang.Object pObj0)
           
 java.lang.Object get(java.lang.String pAnal)
          Obtains the information specified by the argument pAnal from the pResults argument.
 java.lang.Object get(java.lang.String pAnal, java.lang.Object pObj)
          Obtains the information specified by the argument pAnal and pObj from the pResults argument.
 java.lang.Object get(java.lang.String pAnal, java.lang.Object pObj, java.lang.Object pObj0)
           
 java.lang.Object getRaw(java.lang.String pAnal)
           
 java.lang.Object getRaw(java.lang.String pAnal, java.lang.Object pObj)
           
 java.lang.Object getRaw(java.lang.String pAnal, java.lang.Object pObj, java.lang.Object pObj0)
           
static java.util.List list(java.lang.Object pObj)
           
static java.util.List list(java.lang.Object pObj, java.lang.Object pObj0)
           
static java.util.List list(java.lang.Object pObj, java.lang.Object pObj0, java.lang.Object pObj1)
           
 java.lang.Object put(java.lang.String pAnal, java.lang.Object pVal)
          Registers the result of a flow analysis to this map.
 java.lang.Object put(java.lang.String pAnal, java.lang.Object pObj, java.lang.Object pVal)
          Registers the result of a flow analysis for the specified object to this map.
 java.lang.Object put(java.lang.String pAnal, java.lang.Object pObj, java.lang.Object pObj0, java.lang.Object pVal)
           
 void putAnalyzer(java.lang.String pAnal, java.lang.Class pAnalClass)
           
 void putAnalyzer(java.lang.String pAnal, java.lang.Class pAnalClass, java.lang.String pMethodName)
           
static void putRegClasses(RegisterAnalClasses pRegClasses)
          Specifies which set of analyzer classes to use for the automatic analysis mechanism.
 
Methods inherited from class java.util.HashMap
clear, clone, containsKey, containsValue, entrySet, get, isEmpty, keySet, put, putAll, remove, size, values
 
Methods inherited from class java.util.AbstractMap
equals, hashCode, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Map
equals, hashCode
 

Field Detail

regClasses

protected static RegisterAnalClasses regClasses

fAnalDependenceGraph

public Poset fAnalDependenceGraph

fComrades

public java.util.Map fComrades
Constructor Detail

SelfCollectingResults

public SelfCollectingResults()
Method Detail

putRegClasses

public static void putRegClasses(RegisterAnalClasses pRegClasses)
Specifies which set of analyzer classes to use for the automatic analysis mechanism.


putAnalyzer

public void putAnalyzer(java.lang.String pAnal,
                        java.lang.Class pAnalClass)

putAnalyzer

public void putAnalyzer(java.lang.String pAnal,
                        java.lang.Class pAnalClass,
                        java.lang.String pMethodName)

get

public java.lang.Object get(java.lang.String pAnal)
Obtains the information specified by the argument pAnal from the pResults argument. If pResults does not contain the requested information, analyses to obtain the requested information will be performed, and the result eventually returned.

Parameters:
pAnal - name of the information to retrieve.
Returns:
the requested information.

get

public java.lang.Object get(java.lang.String pAnal,
                            java.lang.Object pObj)
Obtains the information specified by the argument pAnal and pObj from the pResults argument. If pResults does not contain the requested information, analyses to obtain the requested information will be performed, and the result eventually returned.

Parameters:
pAnal - name of the information to retrieve, which serves as a key for the requested information.
pObj - object that serves as another key for the requested information.
Returns:
the requested information.

get

public java.lang.Object get(java.lang.String pAnal,
                            java.lang.Object pObj,
                            java.lang.Object pObj0)

find

public void find(java.lang.String pAnal)

find

public void find(java.lang.String pAnal,
                 java.lang.Object pObj)

find

public void find(java.lang.String pAnal,
                 java.lang.Object pObj,
                 java.lang.Object pObj0)

put

public java.lang.Object put(java.lang.String pAnal,
                            java.lang.Object pVal)
Registers the result of a flow analysis to this map. See put(String, HashMap, Object);

Parameters:
pAnal - analysis name.
pVal - result of the analysis.

put

public java.lang.Object put(java.lang.String pAnal,
                            java.lang.Object pObj,
                            java.lang.Object pVal)
Registers the result of a flow analysis for the specified object to this map. See put(String, Object, HashMap, Object).

Parameters:
pAnal - analysis name.
pObj - object of analysis.
pVal - result of the analysis.

put

public java.lang.Object put(java.lang.String pAnal,
                            java.lang.Object pObj,
                            java.lang.Object pObj0,
                            java.lang.Object pVal)

getRaw

public java.lang.Object getRaw(java.lang.String pAnal)

getRaw

public java.lang.Object getRaw(java.lang.String pAnal,
                               java.lang.Object pObj)

getRaw

public java.lang.Object getRaw(java.lang.String pAnal,
                               java.lang.Object pObj,
                               java.lang.Object pObj0)

containsKey

public boolean containsKey(java.lang.String pAnal)

containsKey

public boolean containsKey(java.lang.String pAnal,
                           java.lang.Object pObj)

containsKey

public boolean containsKey(java.lang.String pAnal,
                           java.lang.Object pObj,
                           java.lang.Object pObj0)

list

public static java.util.List list(java.lang.Object pObj)

list

public static java.util.List list(java.lang.Object pObj,
                                  java.lang.Object pObj0)

list

public static java.util.List list(java.lang.Object pObj,
                                  java.lang.Object pObj0,
                                  java.lang.Object pObj1)