Skip to main content

module lang::php::stats::Unfriendly

rascal-0.43.0
org.rascalmpl.php-analysis-0.3.6

Usage​

import lang::php::stats::Unfriendly;

Dependencies​

import List;
import String;
import Set;
import Relation;
import IO;
import ValueIO;
import Map;
import Node;
import Type;
import util::Math;
import Exception;
import lang::php::util::Utils;
import lang::php::stats::Stats;
import lang::php::ast::System;
import lang::php::util::Corpus;
import lang::php::ast::AbstractSyntax;
import lang::php::config::Config;
import lang::php::analysis::signatures::Summaries;
import lang::php::analysis::includes::IncludeGraph;
import lang::php::analysis::NamePaths;
import lang::csv::IO;

alias VVUType​

rel[int id, str product, str path, int line, str derivableNames,    str assignsThrough, str madeGlobal, str usesLiteralPattern,     str usesForeach, str usesSwitch, str usesConditional, str derivableWithAnnotations,     str notes]

function varVarUses​

VVUType varVarUses(loc fileLoc = getConfig().analysis.baseLoc + "/extract/csvs/VarVarUses.csv")

alias ExprsType​

rel[str product, str version, int array, int fetchArrayDim,     int fetchClassConst, int assign, int assignWithBitwiseAnd, int assignWithBitwiseOr,     int assignWithBitwiseXor, int assignWithConcat, int assignWithDiv,  int assignWithMinus, int assignWithMod, int assignWithMul, int assignWithPlus,  int assignWithRightShift, int assignWithLeftShift, int listAssign, int refAssign,   int binOpBitwiseAnd, int binOpBitwiseOr, int binOpBitwiseXor,   int binOpConcat, int binOpDev, int binOpMinus, int binOpMod, int binOpMul,  int binOpPlus, int binOpRightShift, int binOpLeftShift, int binOpBooleanAnd,    int binOpBooleanOr, int binOpGt, int binOpGeq, int binOpLogicalAnd,     int binOpLogicalOr, int binOpLogicalXor, int binOpNotEqual,     int binOpNotIdentical, int binOpLt, int binOpLeq, int binOpEqual,   int binOpIdentical, int unaryOpBooleanNot, int unaryOpBitwiseNot,   int unaryOpPostDec, int unaryOpPreDec, int unaryOpPostInc, int unaryOpPreInc,   int unaryOpPlus, int unaryOpMinus, int new, int castToInt, int castToBool,  int castToFloat, int castToString, int castToArray, int castToObject,   int castToUnset, int clone, int closure, int fetchConst, int empty, int suppress,   int eval, int exit, int call, int methodCall, int staticCall, int include,  int instanceOf, int isSet, int print, int propertyFetch, int shellExec, int ternary,    int fetchStaticProperty, int scalar, int var, int \list]

function expressionCounts​

ExprsType expressionCounts(loc fileLoc = getConfig().analysis.baseLoc + "/extract/csvs/exprs.csv")

alias FeatsType​

rel[str product, str version, str file, int \break, int \classDef,  int \const, int \continue, int \declare, int \do, int \echo,    int \expressionStatementChainRule, int \for, int \foreach, int \functionDef,    int \global, int \goto, int \haltCompiler, int \if, int \inlineHTML,    int \interfaceDef, int \traitDef, int \label, int \namespace, int \return,  int \static, int \switch, int \throw, int \tryCatch, int \unset, int \use,  int \while, int \array, int \fetchArrayDim, int \fetchClassConst, int \assign,  int \assignWithOperationBitwiseAnd, int \assignWithOperationBitwiseOr,  int \assignWithOperationBitwiseXor, int \assignWithOperationConcat,     int \assignWithOperationDiv, int \assignWithOperationMinus,     int \assignWithOperationMod, int \assignWithOperationMul,   int \assignWithOperationPlus, int \assignWithOperationRightShift,   int \assignWithOperationLeftShift, int \listAssign, int \refAssign,     int \binaryOperationBitwiseAnd, int \binaryOperationBitwiseOr,  int \binaryOperationBitwiseXor, int \binaryOperationConcat,     int \binaryOperationDiv, int \binaryOperationMinus, int \binaryOperationMod,    int \binaryOperationMul, int \binaryOperationPlus, int \binaryOperationRightShift,  int \binaryOperationLeftShift, int \binaryOperationBooleanAnd,  int \binaryOperationBooleanOr, int \binaryOperationGt, int \binaryOperationGeq,     int \binaryOperationLogicalAnd, int \binaryOperationLogicalOr,  int \binaryOperationLogicalXor, int \binaryOperationNotEqual,   int \binaryOperationNotIdentical, int \binaryOperationLt, int \binaryOperationLeq,  int \binaryOperationEqual, int \binaryOperationIdentical,   int \unaryOperationBooleanNot, int \unaryOperationBitwiseNot,   int \unaryOperationPostDec, int \unaryOperationPreDec, int \unaryOperationPostInc,  int \unaryOperationPreInc, int \unaryOperationUnaryPlus,    int \unaryOperationUnaryMinus, int \new, int \castToInt, int \castToBool,   int \castToFloat, int \castToString, int \castToArray, int \castToObject,   int \castToUnset, int \clone, int \closure, int \fetchConst, int \empty,    int \suppress, int \eval, int \exit, int \call, int \methodCall, int \staticCall,   int \include, int \instanceOf, int \isSet, int \print, int \propertyFetch,  int \shellExec, int \ternary, int \fetchStaticProperty, int \scalar, int \var,  int \list, int \propertyDef, int \classConstDef, int \methodDef, int \traitUse]

function getFeats​

FeatsType getFeats(loc fileLoc = getConfig().analysis.baseLoc + "/extract/csvs/FeaturesByFile.csv")

alias LinesType​

rel[str product, str version, str file, int phpLines]

function getLines​

LinesType getLines(loc fileLoc = getConfig().analysis.baseLoc + "/extract/csvs/linesPerFile.csv")

alias VersionsType​

rel[str product, str version, str releaseDate, str requiredPHPVersion, str comments]

function getVersions​

VersionsType getVersions(loc fileLoc = getConfig().analysis.baseLoc + "/extract/csvs/Versions.csv")

data QueryResult​

data QueryResult  
= exprResult(loc l, Expr e)
;

alias QueryResults​

list[QueryResult]

function mygini​

real mygini(lrel[num observation,int frequency] values)

real mygini(list[num] dist)

function getVVUses​

QueryResults getVVUses(str product, str version)

rel[str p, str v, QueryResult qr] getVVUses(Corpus corpus)

function getVVUsesAsList​

lrel[str p, str v, QueryResult qr] getVVUsesAsList(Corpus corpus)

function getVVNews​

QueryResults getVVNews(str product, str version)

function getVVNewsAsList​

lrel[str p, str v, QueryResult qr] getVVNewsAsList(Corpus corpus)

function getVVCalls​

QueryResults getVVCalls(str product, str version)

function getVVCallsAsList​

lrel[str p, str v, QueryResult qr] getVVCallsAsList(Corpus corpus)

function getVVMethodCalls​

QueryResults getVVMethodCalls(str product, str version)

function getVVMethodCallsAsList​

lrel[str p, str v, QueryResult qr] getVVMethodCallsAsList(Corpus corpus)

function getVVPropertyRefs​

QueryResults getVVPropertyRefs(str product, str version)

function getVVPropertyRefsAsList​

lrel[str p, str v, QueryResult qr] getVVPropertyRefsAsList(Corpus corpus)

function getVVClassConsts​

QueryResults getVVClassConsts(str product, str version)

function getVVClassConstsAsList​

lrel[str p, str v, QueryResult qr] getVVClassConstsAsList(Corpus corpus)

function getVVStaticCalls​

QueryResults getVVStaticCalls(str product, str version)

function getVVStaticCallsAsList​

lrel[str p, str v, QueryResult qr] getVVStaticCallsAsList(Corpus corpus)

function getVVStaticCallTargets​

QueryResults getVVStaticCallTargets(str product, str version)

function getVVStaticCallTargetsAsList​

lrel[str p, str v, QueryResult qr] getVVStaticCallTargetsAsList(Corpus corpus)

function getVVStaticPropNames​

QueryResults getVVStaticPropNames(str product, str version)

function getVVStaticPropNamesAsList​

lrel[str p, str v, QueryResult qr] getVVStaticPropNamesAsList(Corpus corpus)

function getVVStaticPropTargets​

QueryResults getVVStaticPropTargets(str product, str version)

function getVVStaticPropTargetsAsList​

lrel[str p, str v, QueryResult qr] getVVStaticPropTargetsAsList(Corpus corpus)

data VVInfo​

data VVInfo  
= vvInfo(
lrel[str p, str v, QueryResult qr] vvuses,
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvcconsts,
lrel[str p, str v, QueryResult qr] vvscalls,
lrel[str p, str v, QueryResult qr] vvstargets,
lrel[str p, str v, QueryResult qr] vvsprops,
lrel[str p, str v, QueryResult qr] vvsptargets)
;

function toVVInfo​

VVInfo toVVInfo(tuple[lrel[str p, str v, QueryResult qr] vvuses, 
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvcconsts,
lrel[str p, str v, QueryResult qr] vvscalls,
lrel[str p, str v, QueryResult qr] vvstargets,
lrel[str p, str v, QueryResult qr] vvsprops,
lrel[str p, str v, QueryResult qr] vvsptargets] input)

function getAllVV​

tuple[lrel[str p, str v, QueryResult qr] vvuses, 
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvcconsts,
lrel[str p, str v, QueryResult qr] vvscalls,
lrel[str p, str v, QueryResult qr] vvstargets,
lrel[str p, str v, QueryResult qr] vvsprops,
lrel[str p, str v, QueryResult qr] vvsptargets] getAllVV(Corpus corpus)

tuple[lrel[str p, str v, QueryResult qr] vvuses,
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvcconsts,
lrel[str p, str v, QueryResult qr] vvscalls,
lrel[str p, str v, QueryResult qr] vvstargets,
lrel[str p, str v, QueryResult qr] vvsprops,
lrel[str p, str v, QueryResult qr] vvsptargets] getAllVV(str product, str version, System ptmap)

function showOrderedRel​

lrel[str p, str path, int line] showOrderedRel(rel[str p, str v, QueryResult qr] res)

function writeOrderedRel​

void writeOrderedRel(rel[str p, str v, QueryResult qr] res, loc writeLoc)

function varVarUsesInfo​

map[str,tuple[int totalCount, int derivableCount]] varVarUsesInfo(Corpus corpus)

function showUsageCounts​

void showUsageCounts(Corpus corpus, lrel[str p, str v, QueryResult qr] res)

function showFileInfo​

void showFileInfo(Corpus corpus, lrel[str p, str v, QueryResult qr] res)

function createSubfloat​

str createSubfloat(lrel[str p, str v, QueryResult qr] qrlist, str caption, str label)

function showVVInfoAsLatex​

str showVVInfoAsLatex(lrel[str p, str v, QueryResult qr] vvuses, 
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvall,
map[str,set[loc]] transitiveUses, Corpus corpus)

function saveVVFiles​

void saveVVFiles(lrel[str p, str v, QueryResult qr] vvuses, 
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvcconsts,
lrel[str p, str v, QueryResult qr] vvscalls,
lrel[str p, str v, QueryResult qr] vvstargets,
lrel[str p, str v, QueryResult qr] vvsprops,
lrel[str p, str v, QueryResult qr] vvsptargets
)

function loadVVFiles​

tuple[lrel[str p, str v, QueryResult qr] vvuses, 
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvcconsts,
lrel[str p, str v, QueryResult qr] vvscalls,
lrel[str p, str v, QueryResult qr] vvstargets,
lrel[str p, str v, QueryResult qr] vvsprops,
lrel[str p, str v, QueryResult qr] vvsptargets] loadVVFiles()

function generateTableFiles​

void generateTableFiles(lrel[str p, str v, QueryResult qr] vvuses, 
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvcconsts,
lrel[str p, str v, QueryResult qr] vvscalls,
lrel[str p, str v, QueryResult qr] vvstargets,
lrel[str p, str v, QueryResult qr] vvsprops,
lrel[str p, str v, QueryResult qr] vvsptargets,
map[str,set[loc]] transitiveUses,
Corpus corpus
)

function resultsToGini​

map[str p, real gc] resultsToGini(lrel[str p, str v, QueryResult qr] res)

alias ICLists​

map[tuple[str product, str version] sysinfo, tuple[lrel[loc fileloc, Expr call] initial, lrel[loc fileloc, Expr call] unresolved] hits]

function saveForLater​

void saveForLater(ICLists res)

function reload​

ICLists reload()

alias IncludesCountTuple​

tuple[int includeCount, int fileCount, real giniCoefficient]

alias IncludesCountBeforeAfterTuple​

tuple[IncludesCountTuple initial, IncludesCountTuple unresolved]

alias ICResult​

map[tuple[str product, str version] sysinfo, IncludesCountBeforeAfterTuple counts]

function calculateSystemIncludesCounts​

IncludesCountBeforeAfterTuple calculateSystemIncludesCounts(System sys, rel[loc,loc,loc] resolved)

function includesCountsExists​

bool includesCountsExists()

function saveIncludesCounts​

void saveIncludesCounts(ICResult res)

function loadIncludesCounts​

ICResult loadIncludesCounts()

function includeCounts​

map[tuple[str p, str v], int] includeCounts(Corpus corpus)

function saveTotalIncludes​

void saveTotalIncludes(map[tuple[str p, str v], int] ti)

function loadTotalIncludes​

map[tuple[str p, str v], int] loadTotalIncludes()

function generateIncludeCountsTable​

str generateIncludeCountsTable(ICResult counts, map[tuple[str p, str v], int] totalIncludes)

str generateIncludeCountsTable(ICResult counts, map[tuple[str p, str v], int] totalIncludes, str caption, str texlabel)

function writeIncludeCountsTable​

void writeIncludeCountsTable(ICResult counts, map[tuple[str p, str v], int] totalIncludes)

alias MMResult​

map[tuple[str p, str v], tuple[list[ClassItem] sets, list[ClassItem] gets, list[ClassItem] isSets, list[ClassItem] unsets, list[ClassItem] calls, list[ClassItem] staticCalls]]

function magicMethodUses​

MMResult magicMethodUses(Corpus corpus)

function magicMethodCounts​

str magicMethodCounts(Corpus corpus, MMResult res, map[str,set[loc]] transitiveUses)

alias HistInfo​

rel[str p, str file, int variableVariables, int variableCalls, int variableMethodCalls, int variableNews,                       int variableProperties, int variableClassConsts, int variableStaticCalls, int variableStaticTargets,                      int variableStaticProperties, int variableStaticPropertyTargets]

function calculateHistData​

HistInfo calculateHistData(lrel[str p, str v, QueryResult qr] vvuses, 
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvcconsts,
lrel[str p, str v, QueryResult qr] vvscalls,
lrel[str p, str v, QueryResult qr] vvstargets,
lrel[str p, str v, QueryResult qr] vvsprops,
lrel[str p, str v, QueryResult qr] vvsptargets)

function writeHistInfo​

void writeHistInfo(loc l, HistInfo h)

function readHistInfo​

HistInfo readHistInfo(loc l)

function writeHistInfoCSV​

void writeHistInfoCSV(HistInfo h)

function squiglies​

str squiglies(HistInfo hi)

function squigly​

str squigly(rel[str, int] counts, str label)

function squiglyRound​

str squiglyRound(rel[str, int] counts, str label)

function squigly2​

str squigly2(rel[str, int] counts, str label)

function squigly3​

str squigly3(rel[str, int] counts, str label, map[str,str] printingGroups)

function labeledSquigly​

str labeledSquigly(rel[str, int] counts, str label)

function featureCountsPerFile​

void featureCountsPerFile(Corpus corpus)

alias FMap​

map[str file,tuple[int \break,int \classDef,int \const,int \continue,int \declare,int \do,int \echo,int \expressionStatementChainRule,int \for,int \foreach,int \functionDef,int \global,int \goto,int \haltCompiler,int \if,int \inlineHTML,int \interfaceDef,int \traitDef,int \label,int \namespace,int \return,int \static,int \switch,int \throw,int \tryCatch,int \unset,int \use,int \while,int \array,int \fetchArrayDim,int \fetchClassConst,int \assign,int \assignWithOperationBitwiseAnd,int \assignWithOperationBitwiseOr,int \assignWithOperationBitwiseXor,int \assignWithOperationConcat,int \assignWithOperationDiv,int \assignWithOperationMinus,int \assignWithOperationMod,int \assignWithOperationMul,int \assignWithOperationPlus,int \assignWithOperationRightShift,int \assignWithOperationLeftShift,int \listAssign,int \refAssign,int \binaryOperationBitwiseAnd,int \binaryOperationBitwiseOr,int \binaryOperationBitwiseXor,int \binaryOperationConcat,int \binaryOperationDiv,int \binaryOperationMinus,int \binaryOperationMod,int \binaryOperationMul,int \binaryOperationPlus,int \binaryOperationRightShift,int \binaryOperationLeftShift,int \binaryOperationBooleanAnd,int \binaryOperationBooleanOr,int \binaryOperationGt,int \binaryOperationGeq,int \binaryOperationLogicalAnd,int \binaryOperationLogicalOr,int \binaryOperationLogicalXor,int \binaryOperationNotEqual,int \binaryOperationNotIdentical,int \binaryOperationLt,int \binaryOperationLeq,int \binaryOperationEqual,int \binaryOperationIdentical,int \unaryOperationBooleanNot,int \unaryOperationBitwiseNot,int \unaryOperationPostDec,int \unaryOperationPreDec,int \unaryOperationPostInc,int \unaryOperationPreInc,int \unaryOperationUnaryPlus,int \unaryOperationUnaryMinus,int \new,int \castToInt,int \castToBool,int \castToFloat,int \castToString,int \castToArray,int \castToObject,int \castToUnset,int \clone,int \closure,int \fetchConst,int \empty,int \suppress,int \eval,int \exit,int \call,int \methodCall,int \staticCall,int \include,int \instanceOf,int \isSet,int \print,int \propertyFetch,int \shellExec,int \ternary,int \fetchStaticProperty,int \scalar,int \var,int \list,int \propertyDef,int \classConstDef,int \methodDef,int \traitUse] counts]

function saveFeatsMap​

void saveFeatsMap(FMap m)

function loadFeatsMap​

FMap loadFeatsMap()

function featsMapExists​

bool featsMapExists()

function getFeatureGroups​

map[str,list[str]] getFeatureGroups()

function groupsTable​

str groupsTable(set[str] notIn80, set[str] notIn90, set[str] notIn100)

str groupsTable()

function getFeatureLabels​

list[str] getFeatureLabels()

function generalFeatureSquiglies​

str generalFeatureSquiglies(FMap featsMap)

function shortLabel​

str shortLabel(str l)

function fileSizesHistogram​

str fileSizesHistogram(LinesType ls)

function cumulative​

map[int,int] cumulative(map[int bucket,int frequency] dist)

function almostAll​

tuple[int threshold, int after] almostAll(map[int bucket, int cumulativeFrequency] dist)

function main​

int main()

data FeatureNode​

data FeatureNode (set[str] files={}, set[str] transFiles={}, real percent=0.0) 
= featureNode(set[str] features)
| synthNode(set[str] features)
;

alias FeatureLattice​

rel[FeatureNode,FeatureNode]

function buildFeatureLattice​

FeatureLattice buildFeatureLattice(map[int,set[FeatureNode]] nodesBySize, FeatureNode bottomNode, int totalFiles)

function getFMap​

FMap getFMap()

function calculateFeatureLattice​

FeatureLattice calculateFeatureLattice(FMap fmap)

function calculateTransitiveFiles​

FeatureLattice calculateTransitiveFiles(FeatureLattice lattice, FeatureNode top, int totalFiles)

function minimumFeaturesForPercent​

tuple[set[FeatureNode],set[str],int] minimumFeaturesForPercent(FMap fmap, FeatureLattice lattice, int targetPercent)

alias CoverageMap​

map[int,set[str]]

function minimumFeaturesForPercent2​

CoverageMap minimumFeaturesForPercent2(FMap fmap, FeatureLattice lattice)

function featuresForPercents​

CoverageMap featuresForPercents(FMap fmap, FeatureLattice lattice, list[int] percents)

function featuresForAllPercents​

CoverageMap featuresForAllPercents(FMap fmap, FeatureLattice lattice)

function saveCoverageMap​

void saveCoverageMap(CoverageMap coverageMap)

function loadCoverageMap​

CoverageMap loadCoverageMap()

function coverageMapExists​

bool coverageMapExists()

function saveFeatureLattice​

void saveFeatureLattice(FeatureLattice fl)

function loadFeatureLattice​

FeatureLattice loadFeatureLattice()

function featureLatticeExists​

bool featureLatticeExists()

function coverageGraph​

str coverageGraph(CoverageMap coverageMap)

function vvUsagePatternsTable​

str vvUsagePatternsTable(Corpus corpus)

function getVVLocs​

set[loc] getVVLocs(lrel[str p, str v, QueryResult qr] vv)

set[loc] getVVLocs(str p, str v, lrel[str p, str v, QueryResult qr] vv)

function calculateFeatureTrans​

set[loc] calculateFeatureTrans(rel[loc,loc,loc] includes, set[loc] featureLocs)

Given an includes graph and a set of files, return these files plus the files that (transitively) import them.

function calculateVVTransIncludes​

map[str,set[loc]] calculateVVTransIncludes(
lrel[str p, str v, QueryResult qr] vvuses,
lrel[str p, str v, QueryResult qr] vvcalls,
lrel[str p, str v, QueryResult qr] vvmcalls,
lrel[str p, str v, QueryResult qr] vvnews,
lrel[str p, str v, QueryResult qr] vvprops,
lrel[str p, str v, QueryResult qr] vvcconsts,
lrel[str p, str v, QueryResult qr] vvscalls,
lrel[str p, str v, QueryResult qr] vvstargets,
lrel[str p, str v, QueryResult qr] vvsprops,
lrel[str p, str v, QueryResult qr] vvsptargets,
Corpus corpus,
map[tuple[str p, str v], rel[loc,loc,loc]] includes)

function calculateMMTransIncludes​

map[str,set[loc]] calculateMMTransIncludes(Corpus corpus, MMResult mmr, map[tuple[str p, str v], rel[loc,loc,loc]] includes)

function loadBinaryWithIncludes​

System loadBinaryWithIncludes(str product, str version)

function notCoveredBySystem​

NotCoveredMap notCoveredBySystem(Corpus corpus, FeatureLattice lattice, CoverageMap coverageMap)

alias NotCoveredMap​

map[str product, tuple[set[str] notIn80, set[str] notIn90] filesNotCovered]

function writeNotCoveredInfo​

void writeNotCoveredInfo(NotCoveredMap notCovered)

function readNotCoveredInfo​

NotCoveredMap readNotCoveredInfo()

function coverageComparison​

str coverageComparison(Corpus corpus, NotCoveredMap ncm)

alias EvalUses​

rel[str product, str version, loc fileloc, Expr call]

function corpusEvalUses​

EvalUses corpusEvalUses(Corpus corpus)

function saveEvalUses​

void saveEvalUses(EvalUses evalUses)

function loadEvalUses​

EvalUses loadEvalUses()

function calculateEvalTransIncludes​

map[str,set[loc]] calculateEvalTransIncludes(Corpus corpus, EvalUses evalUses, map[tuple[str p, str v], rel[loc,loc,loc]] includes)

function calculateFunctionTransIncludes​

map[str,set[loc]] calculateFunctionTransIncludes(Corpus corpus, FunctionUses fuses, map[tuple[str p, str v], rel[loc,loc,loc]] includes)

function evalCounts​

str evalCounts(Corpus corpus, EvalUses evalUses, FunctionUses fuses, map[str,set[loc]] transEvals, map[str,set[loc]] transFuses)

alias FunctionUses​

rel[str product, str version, loc fileloc, Expr call]

function systemFunctionUses​

FunctionUses systemFunctionUses(str product, str version, System sys)

function corpusFunctionUses​

FunctionUses corpusFunctionUses(Corpus corpus)

function saveFunctionUses​

void saveFunctionUses(FunctionUses functionUses)

function loadFunctionUses​

FunctionUses loadFunctionUses()

function functionUsesByFun​

void functionUsesByFun(FunctionUses functionUses)

function functionUsesCounts​

str functionUsesCounts(Corpus corpus, FunctionUses functionUses)

function filterFunctionUses​

FunctionUses filterFunctionUses(FunctionUses functionUses, set[str] fnames)

FunctionUses filterFunctionUses(FunctionUses functionUses, str fname)

function createFunctionUses​

FunctionUses createFunctionUses(FunctionUses functionUses)

function invokeFunctionUses​

FunctionUses invokeFunctionUses(FunctionUses functionUses)

function varargsFunctionUses​

FunctionUses varargsFunctionUses(FunctionUses functionUses)

data Def​

data Def  
= functionDef(str functionName, Stmt functionDef, loc defLoc)
| methodDef(str className, str methodName, ClassItem methodDef, loc defLoc)
;

function varargsFunctionsAndMethods​

set[Def] varargsFunctionsAndMethods(System sys)

rel[str p, str v, Def d] varargsFunctionsAndMethods(Corpus corpus)

function varargsCalls​

rel[loc,Expr,bool] varargsCalls(System sys)

rel[str,str,loc,Expr,bool] varargsCalls(Corpus corpus)

function allCalls​

rel[loc,Expr] allCalls(System sys)

rel[str,str,loc,Expr] allCalls(Corpus corpus)

function saveAllCalls​

void saveAllCalls(rel[str,str,loc,Expr] calls)

function loadAllCalls​

rel[str,str,loc,Expr] loadAllCalls()

function saveVarargsCalls​

void saveVarargsCalls(rel[str,str,loc,Expr,bool] calls)

function loadVarargsCalls​

rel[str,str,loc,Expr,bool] loadVarargsCalls()

function classAndInterfaceCount​

map[str product,tuple[int classes, int interfaces] ciCount] classAndInterfaceCount(Corpus corpus)

function classAndInterfaceFiles​

rel[str product, str path] classAndInterfaceFiles(Corpus corpus)

function showVarArgsUses​

str showVarArgsUses(Corpus corpus, rel[str p, str v, Def d] vaDefs, rel[str,str,loc,Expr,bool] vaCalls, rel[str,str,int] allCallsCounts, map[str,set[loc]] vatrans)

function invokeFunctionUsesCounts​

str invokeFunctionUsesCounts(Corpus corpus, FunctionUses functionUses, map[str,set[loc]] transInvokes)

alias TotalRes​

map[tuple[str,str],set[str]]

function whichHaveSomething​

TotalRes whichHaveSomething(Corpus corpus)

function writeMMResults​

void writeMMResults(MMResult mmr)

function loadMMResults​

MMResult loadMMResults()

function totalStats​

rel[str p, str v, int fc, int lc, int dc, real perFiles] totalStats(Corpus corpus, TotalRes tr)