Add an "Event Handler" API to JSPWiki#

There are 3 basic types of events on a Wiki page:

  • Create A new page has been created.
  • Read Someone entered a page
  • Modify someone edited a page.

The idea is that when one of these happens, a list of "event handlers" get invoked. An event handler is a class that implements a perticular interface (just like AWT event handlers). The engine passes an event object containing all there is to know about the event.

Now, where do these handlers come from? Well, they are listed in a file. So, a site manager can define her own handlers, put them under WEB-INF/classes, and add them to the list.

Using this, anyone can contribute implementations for email notification, statistics, content verification (e.g. - scan for viruses) etc.

We could also consider other events, like:

  • User Events
    • new user
    • user loged in
    • user loged out
  • Comment events
    • comment added
    • etc.
  • etc.

- YishayMor

Yes, I was thinking about something like this, but not so general. See PageFilters for more discussion.

-- JanneJalkanen

Add new attachment

Only authorized users are allowed to upload new attachments.
« This page (revision-5) was last changed on 17-Jul-2006 22:10 by Janne Jalkanen