Skip to content

Commit f76b07b

Browse files
committed
JavaDoc
1 parent 95415f5 commit f76b07b

1 file changed

Lines changed: 35 additions & 4 deletions

File tree

soot-infoflow-summaries/src/soot/jimple/infoflow/methodSummary/taintWrappers/ReportMissingSummaryWrapper.java

Lines changed: 35 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@
2727
import soot.SootMethod;
2828
import soot.jimple.infoflow.methodSummary.data.provider.IMethodSummaryProvider;
2929

30+
/**
31+
* Reports missing summaries by writing the results to a XML file.
32+
*/
3033
public class ReportMissingSummaryWrapper extends SummaryTaintWrapper {
3134

3235
public ReportMissingSummaryWrapper(IMethodSummaryProvider flows) {
@@ -60,30 +63,58 @@ private static <T> void count(T item, Map<T, AtomicInteger> map) {
6063
ai.incrementAndGet();
6164
}
6265

66+
/**
67+
* Sets the pretty printing flag. When enabled, pretty printing
68+
* creates new lines for each XML node, and uses indentation for the XML tree
69+
* @param prettyPrint whether pretty printing should be enabled
70+
*/
6371
public void setPrettyPrinting(boolean prettyPrint) {
6472
this.prettyPrint = prettyPrint;
6573
}
6674

75+
/**
76+
* Pretty printing creates new lines for each XML node, and uses indentation for the XML tree
77+
* @return returns true if enabled, otherwise false
78+
*/
6779
public boolean isPrettyPrinting() {
6880
return prettyPrint;
6981
}
7082

83+
/**
84+
* When the given parameter is true, the class also reports application classes,
85+
* i.e. classes that are part of the application being analyzed.
86+
* @param showAppClasses whether app classes should be shown
87+
*/
7188
public void setShowApplicationClasses(boolean showAppClasses) {
7289
this.showAppClasses = showAppClasses;
7390
}
7491

92+
/**
93+
* Returns whether this class also reports application classes,
94+
* i.e. classes that are part of the application being analyzed
95+
* @return returns true if enabled, otherwise false
96+
*/
7597
public boolean isShowingApplicationClasses() {
7698
return showAppClasses;
7799
}
78100

79-
public boolean isCountMethods() {
80-
return countMethods;
81-
}
82-
101+
/**
102+
* If the given parameter is true, this class will report counts
103+
* on a per class and per method basis.
104+
* @param countMethods whether to count methods
105+
*/
83106
public void setCountMethods(boolean countMethods) {
84107
this.countMethods = countMethods;
85108
}
86109

110+
/**
111+
* Returns whether counting methods is enabled
112+
* @return returns true if enabled, otherwise false
113+
*/
114+
public boolean isCountMethods() {
115+
return countMethods;
116+
}
117+
87118
public void writeResults(File file) throws IOException, ParserConfigurationException, TransformerException {
88119
Map<SootClass, Integer> sortedClassSummariesMissing = sortMap(classSummariesMissing);
89120
DocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();

0 commit comments

Comments
 (0)