Overview | Package | Class | Tree | Deprecated | Index | Help
| © 2005 BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.p13n.tracking.listeners
Class BehaviorTrackingListener

    java.lang.Object
      com.bea.p13n.tracking.listeners.BehaviorTrackingListener

All Implemented Interfaces:
  EventListener

public class BehaviorTrackingListener
extends Object
implements EventListener

EventListener to handle all behavior tracking events. Events are persisted to the database. This class should be added to the property eventService.listeners in order to enable behavior tracking.

Constructor Summary
`BehaviorTrackingListener()` Construct an instance of the listener and populate the eventTypes array with the event types that this listener will listen for.

Method Summary
`String[]` | `getTypes()` This method lets the EventListener advertise what types it is interested in.
`void` | `handleEvent(Event theEvent)` Handle the event.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### BehaviorTrackingListener

    public BehaviorTrackingListener()

  Construct an instance of the listener and populate the eventTypes array with the event types that this listener will listen for.

Method Detail

### getTypes

    public String[] getTypes()

  Description copied from interface: `EventListener`
  This method lets the EventListener advertise what types it is interested in. It is used by the EventHandler to dispatch only Events with a matching type to this EventListener. To listen on all events, implement this method to return a String[1] containing EventConstants.TYPE_ALL. Must not return null or return null in any element.

  Specified by:
    `getTypes` in interface `EventListener`
  Returns:
    the event types that are specified (in application-config.xml) and are to be persisted to the database.

### handleEvent

    public void handleEvent(Event theEvent)

  Handle the event. Ensure that it is an instanceof TrackingEvent and add it to a Buffer which will be swept to the database.

  Specified by:
    `handleEvent` in interface `EventListener`
  Parameters:
    `theEvent` - subclass of TrackingEvent to be written to the database

Overview | Package | Class | Tree | Deprecated | Index | Help
| © 2005 BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2005 BEA Systems, Inc. All Rights Reserved