public class UrlRewriteFilter
extends java.lang.Object
implements javax.servlet.Filter
限定符和类型 | 字段和说明 |
---|---|
static java.lang.String |
DEFAULT_MOD_REWRITE_STYLE_CONF_PATH |
static java.lang.String |
DEFAULT_WEB_CONF_PATH |
构造器和说明 |
---|
UrlRewriteFilter() |
限定符和类型 | 方法和说明 |
---|---|
static void |
addRuleUrl(java.lang.String fromPath,
java.lang.String toPath) |
void |
destroy()
Destroy is called by the application server when it unloads this filter.
|
void |
destroyActual() |
void |
doFilter(javax.servlet.ServletRequest request,
javax.servlet.ServletResponse response,
javax.servlet.FilterChain chain)
The main method called for each request that this filter is mapped for.
|
int |
getConfReloadCheckInterval()
The amount of seconds between reload checks.
|
java.util.Date |
getConfReloadLastCheck() |
static java.lang.String |
getFullVersionString() |
static UrlRewriteFilter |
getInstance() |
java.lang.String |
getStatusPath() |
void |
init(javax.servlet.FilterConfig filterConfig)
Init is called automatically by the application server when it creates this filter.
|
boolean |
isConfReloadCheckEnabled() |
boolean |
isLoaded() |
boolean |
isStatusEnabled() |
boolean |
isTimeToReloadConf()
Is it time to reload the configuration now.
|
java.lang.String |
reCheckConfPath(java.lang.String confPath) |
void |
reloadConf()
Forcibly reload the configuration now.
|
static void |
removeRuleUrl(java.lang.String fromPath) |
public static final java.lang.String DEFAULT_WEB_CONF_PATH
public static final java.lang.String DEFAULT_MOD_REWRITE_STYLE_CONF_PATH
public static UrlRewriteFilter getInstance()
public void init(javax.servlet.FilterConfig filterConfig) throws javax.servlet.ServletException
init
在接口中 javax.servlet.Filter
filterConfig
- The config of the filterjavax.servlet.ServletException
public java.lang.String reCheckConfPath(java.lang.String confPath)
public void destroy()
destroy
在接口中 javax.servlet.Filter
public void destroyActual()
public void doFilter(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, javax.servlet.FilterChain chain) throws java.io.IOException, javax.servlet.ServletException
doFilter
在接口中 javax.servlet.Filter
request
- the request to filterresponse
- the response to filterchain
- the chain for the filteringjava.io.IOException
- IOExceptionjavax.servlet.ServletException
- ServletExceptionpublic boolean isTimeToReloadConf()
public void reloadConf()
public boolean isConfReloadCheckEnabled()
public int getConfReloadCheckInterval()
public java.util.Date getConfReloadLastCheck()
public boolean isStatusEnabled()
public java.lang.String getStatusPath()
public boolean isLoaded()
public static void addRuleUrl(java.lang.String fromPath, java.lang.String toPath)
public static void removeRuleUrl(java.lang.String fromPath)
public static java.lang.String getFullVersionString()