📄 filter-library.xtp
字号:
<s1 title="Filter Library"><s2 title='GzipFilter'><p>The GzipFilter compresses the output of pages for browsers whichunderstand compression.</p><example><web-app> <filter-mapping url-pattern='/*' filter-name='com.caucho.http.filter.GzipFilter'/></web-app></example><deftable><tr><td>use-vary<td>Uses the standard Vary header for Accept-Encoding<td>true<tr><td>no-cache<td>Sets the Cache-Control: no-cache header<td>false</deftable></s2><s2 title='TransactionFilter'><p>The TransactionFilter wraps the request in a UserTransaction andcommits the transaction when the servlet completes.</p><example><web-app> <filter-mapping url-pattern='/DatabaseServlet/*' filter-name='com.caucho.http.filter.TransactionFilter'/></web-app></example></s2><s2 title='ExpiresFilter'><p>The ExpiresFilter sets the Expires cache control header, allowingthe servlet output to be cached for a short time.</p><example title="Caching stock quotes for 60 seconds"><web-app> <filter-mapping servlet-name='StockQuoteServlet' filter-name='com.caucho.http.filter.ExpiresFilter'> <init-param cache-time="60s"/> </filter-mapping></web-app></example></s2><s2 title='AnonymousExpiresFilter'><p>The AnonymousExpiresFilter caches output for anonymous, i.e.non-logged in users. When a page has custom formatting forlogged in users, it may still want to cache the results fornon-logged in users saving time and database access.</p><example title="Caching all anonymouse users *.jsp pages for 15 minutes"><web-app> <filter-mapping url-pattern='*.jsp' filter-name='com.caucho.http.filter.AnonymousExpiresFilter'> <init-param cache-time="15m"/> </filter-mapping></web-app></example></s2></s1>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -