Hi,
I have updated the response filter. Now I am passing the servlet for the parameter annotationFile. Please find below the latest response filter code and annotation output. This servlet generates text annotation output. But still the annotation does not work. Please suggest me how to implement this.
Response Filter:
public void filter(String serverType, PluginServiceCallbacks callbacks,
HttpServletRequest request, JSONObject jsonResponse) throws Exception {
logger = callbacks.getLogger();
logger.logDebug(ViewerTest.class, "filter", " **Enter filter7()** , Parameters - callbacks :: "+callbacks
+", request :: "+request+", jsonResponse :: "+jsonResponse);
String lsResponseHTML = (String) jsonResponse.get("responseHTML");
String lsTemp = lsResponseHTML.substring(0,lsResponseHTML.lastIndexOf("</object>"));
String lsAnnotationFile = "<param name=\"annotateEdit\" value=\"true\"/>\\r\\n<param name=\"annotationFile\" value=\"https://servername/AnnotationTest/TextAnnotation\"/>\r\n</object>\r\n";
String lsFinalResponseHTML = lsTemp + lsAnnotationFile;
logger.logDebug(ViewerTest.class, "filter", " lsFinalResponseHTML :: "+lsFinalResponseHTML);
jsonResponse.put("responseHTML", lsFinalResponseHTML);
logger.logDebug(ViewerTest.class, "filter", " final jsonResponse :: "+jsonResponse);
}
Servlet Output:

Viewer Settings after the plug-in deployment:

Current Output: I have updated annotateEdit and annotationFile parameters through response filter. The parameter annotateEdit enabled the Annotation toolbar. The annotationFile parameter also updated but no annotation is being displayed as expected.
------------------------------
RAVI KUMAR
------------------------------