Source: lycad_chargen/modifiereventlistener.h
|
|
|
|
/***************************************************************************
modifiereventlistener.h - description
-------------------
begin : Tue Nov 13 2001
copyright : (C) 2001 by Sheldon Lee Wen
email : tormak@home.com
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
#ifndef MODIFIEREVENTLISTENER_H
#define MODIFIEREVENTLISTENER_H
#include "event.h"
#include "modifiereventgenerator.h"
#include "modifierevent.h"
#include
/**Listener class for a modifierEvent. It recieves an event from a modifierGenerator
and processes it by calling handleModifierEvent. This class is mostly useless
on it's own, it's meant to be inherited. It is inherited by the modifier class.
*@author Sheldon Lee Wen
*/
class modifierGenerator;
class modifierListener : public event_listener {
public:
modifierListener();
virtual ~modifierListener();
// this method needs to be supplied in the derived class
virtual void handleModifierEvent(modifierEvent *evt);
private:
vector modifierGenerators;
int findModifierGenerator(modifierGenerator *g);
void addModifierGenerator(modifierGenerator *g);
void removeModifierGenerator(modifierGenerator *g);
friend modifierGenerator;
};
// this method needs to be supplied in the derived class
//virtual void handleEncounterEvent(EncounterEvent evt) = 0;
#endif
Generated by: sheldonl on cr595811-a on Fri Nov 30 10:24:34 2001, using kdoc 2.0a53. |