Event Interceptors"

From Documentation
m ((via JWB))
m (remove empty version history (via JWB))
 
Line 13: Line 13:
 
</source>
 
</source>
  
=Version History=
 
  
{| class='wikitable' | width="100%"
 
! Version !! Date !! Content
 
|-
 
| &nbsp;
 
| &nbsp;
 
| &nbsp;
 
|}
 
  
 
{{ZKDevelopersReferencePageFooter}}
 
{{ZKDevelopersReferencePageFooter}}

Latest revision as of 10:23, 5 February 2024

Though EventInterceptor is designed to allow developer to intercept how an event is processed, you could use it as callback to know how long it takes to process an event. The event processing time can be calculated by subtracting the time between EventInterceptor.beforeProcessEvent(Event) and EventInterceptor.afterProcessEvent(Event)

Once implemented, you could register it by specifying the following in WEB-INF/zk.xml (assume the class is called foo.MyEventMeter):

<zk>
    <listener>
        <listener-class>foo.MyEventMeter</listener-class>
    </listener>
</zk>




Last Update : 2024/02/05

Copyright © Potix Corporation. This article is licensed under GNU Free Documentation License.