01: /**
02: * Title: <p>
03: * Description: <p>
04: * Copyright: Copyright (c) <p>
05: * Company: <p>
06: * @author
07: * @version 1.0
08: */package com.teamkonzept.web;
09:
10: import com.teamkonzept.lib.TKException;
11:
12: public interface TKEventHandler {
13: /** handles the event */
14: public void handleEvent(TKEvent evt) throws TKException;
15:
16: /** returns true, if it wants to handle this event */
17: public boolean isHandler(TKEvent evt);
18:
19: public void addEventHandler(TKEventHandler handler);
20:
21: public void removeEventHandler(TKEventHandler handler);
22:
23: /** setzt die zu behandelnden Events*/
24: public void setHandleEvents(TKEvent[] events);
25:
26: /** liefert die zu behandelnden Events zurueck */
27: public TKEvent[] getHandleEvents();
28:
29: /**
30: * Creates an event object.
31: *
32: * @param http the responsible HTTP interface.
33: * @return an event object.
34: */
35: public abstract TKEvent createEvent(TKHttpInterface http);
36:
37: }
|