public class IncludeNotFound extends java.lang.Object implements IncludeEventHandler, RuntimeServicesAware, ContextAware
By default, the name of the replacement page is "notfound.vm", however this
page name can be changed by setting the Velocity property
eventhandler.include.notfound, for example:
eventhandler.include.notfound = error.vm
The name of the missing resource is put into the Velocity context, under the
key "missingResource", so that the "notfound" template can report the missing
resource with a Velocity reference, like:
$missingResource
IncludeEventHandler.IncludeEventExecutor| 构造器和说明 |
|---|
IncludeNotFound() |
| 限定符和类型 | 方法和说明 |
|---|---|
java.lang.String |
includeEvent(java.lang.String includeResourcePath,
java.lang.String currentResourcePath,
java.lang.String directiveName)
Chseck to see if included file exists, and display "not found" page if it
doesn't.
|
void |
setContext(Context context)
Initialize the EventHandler.
|
void |
setRuntimeServices(RuntimeServices rs)
Called automatically when event cartridge is initialized.
|
public java.lang.String includeEvent(java.lang.String includeResourcePath,
java.lang.String currentResourcePath,
java.lang.String directiveName)
includeEvent 在接口中 IncludeEventHandlerincludeResourcePath - currentResourcePath - directiveName - public void setRuntimeServices(RuntimeServices rs)
RuntimeServicesAwaresetRuntimeServices 在接口中 RuntimeServicesAwarers - RuntimeServices object assigned during initializationRuntimeServicesAware.setRuntimeServices(bboss.org.apache.velocity.runtime.RuntimeServices)public void setContext(Context context)
ContextAware