mirror of
https://github.com/internetarchive/heritrix3.git
synced 2026-09-24 14:45:56 +00:00
Rename short report methods:
- singleLineReport() -> shortReportLine() - singleLineReportTo() -> shortReportLineTo() - singleLineReportData() -> shortReportMap()
This commit is contained in:
@@ -1486,11 +1486,11 @@ implements MultiReporter, Serializable, OverlayContext {
|
||||
// Reporter implementation
|
||||
//
|
||||
|
||||
public String singleLineReport() {
|
||||
return ArchiveUtils.singleLineReport(this);
|
||||
public String shortReportLine() {
|
||||
return ArchiveUtils.shortReportLine(this);
|
||||
}
|
||||
|
||||
public Map<String, Object> singleLineReportData() {
|
||||
public Map<String, Object> shortReportMap() {
|
||||
Map<String,Object> map = new LinkedHashMap<String, Object>();
|
||||
map.put("class", getClass().getName());
|
||||
map.put("uri", getUURI().toString());
|
||||
@@ -1499,7 +1499,7 @@ implements MultiReporter, Serializable, OverlayContext {
|
||||
return map;
|
||||
}
|
||||
|
||||
public void singleLineReportTo(PrintWriter w) {
|
||||
public void shortReportLineTo(PrintWriter w) {
|
||||
String className = this.getClass().getName();
|
||||
className = className.substring(className.lastIndexOf(".")+1);
|
||||
w.print(className);
|
||||
@@ -1514,7 +1514,7 @@ implements MultiReporter, Serializable, OverlayContext {
|
||||
/* (non-Javadoc)
|
||||
* @see org.archive.util.Reporter#singleLineLegend()
|
||||
*/
|
||||
public String singleLineLegend() {
|
||||
public String shortReportLegend() {
|
||||
return "className uri hopsPath viaUri";
|
||||
}
|
||||
|
||||
@@ -1530,7 +1530,7 @@ implements MultiReporter, Serializable, OverlayContext {
|
||||
* @see org.archive.util.Reporter#reportTo(java.lang.String, java.io.Writer)
|
||||
*/
|
||||
public void reportTo(String name, PrintWriter writer) {
|
||||
singleLineReportTo(writer);
|
||||
shortReportLineTo(writer);
|
||||
writer.print("\n");
|
||||
}
|
||||
|
||||
|
||||
@@ -94,18 +94,18 @@ implements Iterable<Processor>,
|
||||
writer.println();
|
||||
}
|
||||
|
||||
public String singleLineLegend() {
|
||||
public String shortReportLegend() {
|
||||
return "";
|
||||
}
|
||||
|
||||
public Map<String, Object> singleLineReportData() {
|
||||
public Map<String, Object> shortReportMap() {
|
||||
Map<String,Object> data = new LinkedHashMap<String, Object>();
|
||||
data.put("processorCount", size());
|
||||
data.put("processors", getProcessors());
|
||||
return data;
|
||||
}
|
||||
|
||||
public void singleLineReportTo(PrintWriter pw) {
|
||||
public void shortReportLineTo(PrintWriter pw) {
|
||||
pw.print(size());
|
||||
pw.print(" processors: ");
|
||||
for(Processor p : this) {
|
||||
|
||||
@@ -194,8 +194,8 @@ public class FetchStats implements Serializable, FetchStatusCodes, MultiReporter
|
||||
*/
|
||||
public void reportTo(String name, PrintWriter writer) {
|
||||
// name ignored, only one report
|
||||
writer.println(singleLineLegend());
|
||||
singleLineReportTo(writer);
|
||||
writer.println(shortReportLegend());
|
||||
shortReportLineTo(writer);
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
@@ -205,17 +205,17 @@ public class FetchStats implements Serializable, FetchStatusCodes, MultiReporter
|
||||
reportTo(null,writer);
|
||||
}
|
||||
|
||||
public String singleLineLegend() {
|
||||
public String shortReportLegend() {
|
||||
return "totalScheduled fetchSuccesses fetchFailures fetchDisregards " +
|
||||
"fetchResponses robotsDenials successBytes totalBytes " +
|
||||
"fetchNonResponses";
|
||||
}
|
||||
|
||||
public String singleLineReport() {
|
||||
return ArchiveUtils.singleLineReport(this);
|
||||
public String shortReportLine() {
|
||||
return ArchiveUtils.shortReportLine(this);
|
||||
}
|
||||
|
||||
public void singleLineReportTo(PrintWriter writer) {
|
||||
public void shortReportLineTo(PrintWriter writer) {
|
||||
writer.print(totalScheduled);
|
||||
writer.print(" ");
|
||||
writer.print(fetchSuccesses);
|
||||
@@ -235,7 +235,7 @@ public class FetchStats implements Serializable, FetchStatusCodes, MultiReporter
|
||||
writer.print(fetchNonResponses);
|
||||
}
|
||||
|
||||
public Map<String, Object> singleLineReportData() {
|
||||
public Map<String, Object> shortReportMap() {
|
||||
Map<String,Object> map = new LinkedHashMap<String, Object>();
|
||||
map.put("totalScheduled", totalScheduled);
|
||||
map.put("fetchSuccesses", fetchSuccesses);
|
||||
|
||||
Reference in New Issue
Block a user