public interface URIInterceptor
How this interface is used.
request(java.lang.String)is called against the instance created in the previous step.
ExecutionInitand others listeners, the same instance of
URIInterceptoris used for the whole application. Thus, you have to make sure it can be accessed concurrently.
request(java.lang.String)is called even if the page definition is cached.
URIInterceptor is called when retrieving a page definition
from an URI (
PageDefinitions.getPageDefinition(org.zkoss.zk.ui.WebApp, org.zkoss.util.resource.Locator, java.lang.String)). It may or may not be caused by a client request.
On the other hand,
RequestInterceptor is called
when ZK Loader or ZK Update Engine is receiving a client request.
void request(java.lang.String uri) throws java.lang.Exception
To deny the access, the class shall throw an exception. If you want to redirect to another page, you can configure it with <error-page> by specifying the corresponding page and exception in WEB-INF/zk.xml.
Copyright © 2005-2021 Potix Corporation. All Rights Reserved.