MCPcopy Create free account
hub / github.com/apache/tomcat / process

Method process

java/org/apache/catalina/ssi/SSIPrintenv.java:34–59  ·  view source on GitHub ↗
(SSIMediator ssiMediator, String commandName, String[] paramNames, String[] paramValues,
            PrintWriter writer)

Source from the content-addressed store, hash-verified

32 }
33
34 @Override
35 public long process(SSIMediator ssiMediator, String commandName, String[] paramNames, String[] paramValues,
36 PrintWriter writer) {
37 long lastModified = 0;
38 // any arguments should produce an error
39 if (paramNames.length > 0) {
40 String errorMessage = ssiMediator.getConfigErrMsg();
41 writer.write(errorMessage);
42 } else {
43 Collection<String> variableNames = ssiMediator.getVariableNames();
44 for (String variableName : variableNames) {
45 String variableValue = ssiMediator.getVariableValue(variableName, SSIMediator.ENCODING_ENTITY);
46 // This shouldn't happen, since all the variable names must
47 // have values
48 if (variableValue == null) {
49 variableValue = "(none)";
50 }
51 writer.write(variableName);
52 writer.write('=');
53 writer.write(variableValue);
54 writer.write('\n');
55 lastModified = System.currentTimeMillis();
56 }
57 }
58 return lastModified;
59 }
60}

Callers

nothing calls this directly

Calls 4

getConfigErrMsgMethod · 0.80
getVariableNamesMethod · 0.80
writeMethod · 0.65
getVariableValueMethod · 0.65

Tested by

no test coverage detected