# HG changeset patch
# User robcast
# Date 1088503597 -7200
# Node ID 9f596e9ab6fb1073fd26f14f4edcf45dde8e37bf
# Parent 050fa739066fe6e8a561a4e027f1537ae6af319f
digilib directory cache information
diff -r 050fa739066f -r 9f596e9ab6fb client/digitallibrary/server/dlCache.jsp
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/client/digitallibrary/server/dlCache.jsp Tue Jun 29 12:06:37 2004 +0200
@@ -0,0 +1,73 @@
+<%@ page language="java" %>
+
+<%!
+// authentication stuff - robert
+// -----------------------------
+// create DocumentBean instance for all JSP requests
+digilib.servlet.DocumentBean docBean = new digilib.servlet.DocumentBean();
+
+// initialize DocumentBean instance in JSP init
+public void jspInit() {
+ try {
+ // set servlet init-parameter
+ docBean.setConfig(getServletConfig());
+ } catch (javax.servlet.ServletException e) {
+ System.out.println(e);
+ }
+}
+%>
+
+<%
+// get digilib config
+digilib.servlet.DigilibConfiguration dlConfig = docBean.getDlConfig();
+// dir cache
+digilib.io.DocuDirCache dirCache = (digilib.io.DocuDirCache) dlConfig.getValue("servlet.dir.cache");
+%>
+
+
+
+Digilib cache info
+
+
+Digilib cache info
+
+
+
+
+ size (directories) | <%= dirCache.size() %> |
+ |
+
+
+ numFiles | <%= dirCache.getNumFiles() %> |
+ |
+
+
+ hits | <%= dirCache.getHits() %> |
+ |
+
+
+ misses | <%= dirCache.getMisses() %> |
+ |
+
+
+
+
+<%
+ Object[] keys = dirCache.getChildren("", true).toArray();
+ java.util.Arrays.sort(keys);
+ int l = keys.length;
+ for (int i = 0; i < l; i++) {
+ String key = (String) keys[i];
+ // digilib.io.DocuDirectory val = (digilib.io.DocuDirectory) dirCache.getDirectory(key);
+%>
+
+ <%= key %> | <%= 1 /* val.getDirName() */ %> |
+ |
+
+<%
+ }
+%>
+
+
+
+