Skip to content

Commit 04bb4c6

Browse files
author
Vladimir Kotal
committed
add comments, merge lines
1 parent 92f4530 commit 04bb4c6

File tree

1 file changed

+10
-16
lines changed

1 file changed

+10
-16
lines changed

opengrok-web/src/main/webapp/list.jsp

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ document.pageReady.push(function() { pageReadyList();});
266266
// find the definitions in the index.
267267
Definitions defs = IndexDatabase.getDefinitions(resourceFile);
268268
Annotation annotation = cfg.getAnnotation();
269-
// SRCROOT is read with UTF-8 as a default.
269+
// Data under source root is read with UTF-8 as a default.
270270
r = IOUtils.createBOMStrippedReader(bin,
271271
StandardCharsets.UTF_8.name());
272272
AnalyzerGuru.writeDumpedXref(request.getContextPath(), a,
@@ -312,8 +312,7 @@ Click <a href="<%= rawPath %>">download <%= basename %></a><%
312312
in = new BufferedInputStream(new FileInputStream(resourceFile));
313313
} else {
314314
tempf = File.createTempFile("ogtags", basename);
315-
if (HistoryGuru.getInstance().getRevision(tempf,
316-
resourceFile.getParent(), basename, rev)) {
315+
if (HistoryGuru.getInstance().getRevision(tempf, resourceFile.getParent(), basename, rev)) {
317316
in = new BufferedInputStream(new FileInputStream(tempf));
318317
} else {
319318
tempf.delete();
@@ -346,8 +345,7 @@ Click <a href="<%= rawPath %>">download <%= basename %></a><%
346345
<pre><%
347346
if (g == AbstractAnalyzer.Genre.PLAIN) {
348347
Definitions defs = null;
349-
ObjectPool<Ctags> ctagsPool = cfg.getEnv().
350-
getIndexerParallelizer().getCtagsPool();
348+
ObjectPool<Ctags> ctagsPool = cfg.getEnv().getIndexerParallelizer().getCtagsPool();
351349
int tries = 2;
352350
while (cfg.getEnv().isWebappCtags()) {
353351
Ctags ctags = ctagsPool.get();
@@ -358,8 +356,7 @@ Click <a href="<%= rawPath %>">download <%= basename %></a><%
358356
break;
359357
} catch (InterruptedException ex) {
360358
if (--tries > 0) {
361-
LOGGER.log(Level.WARNING,
362-
"doCtags() interrupted--{0}",
359+
LOGGER.log(Level.WARNING, "doCtags() interrupted--{0}",
363360
ex.getMessage());
364361
continue;
365362
}
@@ -376,25 +373,23 @@ Click <a href="<%= rawPath %>">download <%= basename %></a><%
376373
Annotation annotation = cfg.getAnnotation();
377374
//not needed yet
378375
//annotation.writeTooltipMap(out);
379-
// SRCROOT is read with UTF-8 as a default.
380-
r = IOUtils.createBOMStrippedReader(in,
381-
StandardCharsets.UTF_8.name());
382-
AnalyzerGuru.writeDumpedXref(
383-
request.getContextPath(),
376+
// The data under source root is read with UTF-8 as a default.
377+
r = IOUtils.createBOMStrippedReader(in, StandardCharsets.UTF_8.name());
378+
AnalyzerGuru.writeDumpedXref(request.getContextPath(),
384379
a, r, out,
385380
defs, annotation, project);
386381
} else if (g == AbstractAnalyzer.Genre.IMAGE) {
387382
%></pre>
388383
<img src="<%= rawPath %>?<%= QueryParameters.REVISION_PARAM_EQ %><%= Util.URIEncode(rev) %>"/>
389384
<pre><%
390385
} else if (g == AbstractAnalyzer.Genre.HTML) {
391-
/**
386+
/*
392387
* For backward compatibility, read the
393388
* OpenGrok-produced document using the system
394389
* default charset.
395390
*/
396391
r = new InputStreamReader(in);
397-
/**
392+
/*
398393
* dumpXref() is also useful here for
399394
* translating links.
400395
*/
@@ -444,8 +439,7 @@ Click <a href="<%= rawPath %>">download <%= basename %></a><%
444439
}
445440
}
446441
} else {
447-
// requesting cross referenced file
448-
442+
// Requesting cross referenced file with no known revision.
449443
File xrefFile = cfg.findDataFile();
450444
if (xrefFile != null) {
451445
%>

0 commit comments

Comments
 (0)