com.bea.netuix.servlets.controls.analytics
Interface AnalyticEventHandler


public interface AnalyticEventHandler

Service-provider interface for AnalyticEventHandler implementations.

An analytic event handler is a concrete subclass of this interface that has a public no- argument constructor and implements the interface methods specified below.

An AnalyticEventHandler implementer should generally package their provider in a jar. That jar should consist of any necessary classes (including, of course, an implementation of AnalyticEventHandler), as well as a file named META-INF/services/com.bea.netuix.servlets.controls.analytics.AnalyticEventHandler. That services file must contain one and only one class name which must be a concrete AnalyticEventHandler implementation.

The provider jar(s) should then be deployed with the application by including the jar in the webapp's WED-INF/lib directory. Provider jars may also be included in the application or system classpath, although this changes the scoping of the provider class objects, and causes the provider implementations to be shared by multiple web apps.

On initialization, the AnalyticEventDispatcher will load such provider. Id the Dispatcher fails to load or initialize the event handler a error message will be logged and no event handling will take place.

NOTE: Implementations of the interface methods must be safe for use by multiple concurrent threads.


Method Summary
 void dispose()
          Implementation class may perform cleanup operations here.
 void init()
          Implementation class may perform any one-time initializations here.
 void log(AnalyticEvent analyticEvent)
          This method is called by the container at the end of each page's and portlet's run.
 

Method Detail

init

void init()

Implementation class may perform any one-time initializations here. If this method fails (throws an exception) the event handler will not be registered and no event handling will take place.


log

void log(AnalyticEvent analyticEvent)

This method is called by the container at the end of each page's and portlet's run. It is invoked for every page and portlet on every request. Since this method is called so frequently the implementation must be extremely efficient, or the entire portal's performace will suffer.

Parameters
analyticEvent - the event to be logged.

dispose

void dispose()

Implementation class may perform cleanup operations here. Note: there is no guarantee this method will be called.



Copyright © 2000, 2009, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its affiliates.
Other names may be trademarks of their respective owners.