Ignore:
Timestamp:
04/23/15 03:16:55 (7 years ago)
Author:
Maciej Komosinski
Message:

Less cryptic variable names

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/frams/mhandlers/mhandlers.h

    r372 r373  
    3939        friend class MessageHandlerManager;
    4040protected:
    41         MessageHandlerManager* mgr;
     41        MessageHandlerManager* manager;
    4242        int options;
    4343
     
    5252        void send(const char *o, const char *m, const char *bl, int w);
    5353
    54         bool isEnabled() { return mgr ? 1 : 0; }
     54        bool isEnabled() { return manager ? true : false; }
    5555        void enable();
    5656        void disable();
     
    5959        void resume();
    6060
    61         MessageHandlerBase(int opts = 0) :mgr(0), options(opts)
     61        MessageHandlerBase(int opts = 0) :manager(NULL), options(opts)
    6262        {
    6363                if (options&Enable) enable();
     
    7676{
    7777protected:
    78         int maxlevel, errcount, warncount, storlevel, storcount, infocount;
     78        int maxlevel, minleveltostore, errcount, warncount, storedcount, infocount;
    7979        SString msgs;
    8080
    8181public:
    8282
    83         void reset() { maxlevel = HMLV_INFO - 1; errcount = warncount = storcount = infocount = 0; msgs = 0; }
     83        void reset() { maxlevel = HMLV_INFO - 1; errcount = warncount = storedcount = infocount = 0; msgs = 0; }
    8484
    8585        enum Options2
     
    9191        int getWarningCount()     { return warncount; }
    9292        int getInfoCount()        { return infocount; }
    93         int getStoredCount()      { return storcount; }
     93        int getStoredCount()      { return storedcount; }
    9494        int getErrorLevel()       { return maxlevel; }
    9595        const SString& getMessages() { return msgs; }
    9696
    97         MessageHandlerToMemory(int opts = 0, int minimal_level_to_store = HMLV_ERROR) :MessageHandlerBase(opts), storlevel(minimal_level_to_store)
     97        MessageHandlerToMemory(int opts = 0, int minimal_level_to_store = HMLV_ERROR) :MessageHandlerBase(opts), minleveltostore(minimal_level_to_store)
    9898        {
    9999                reset();
     
    105105class RedirectingMessageHandler : public MessageHandlerBase
    106106{
    107         MessageHandlerManager *other_mgr;
     107        MessageHandlerManager *other_manager;
    108108public:
    109         RedirectingMessageHandler(MessageHandlerManager *om,int opts=0)
    110                 :MessageHandlerBase(opts), other_mgr(om) {}
     109        RedirectingMessageHandler(MessageHandlerManager *other_mgr,int opts=0)
     110                :MessageHandlerBase(opts), other_manager(other_mgr) {}
    111111
    112112        void handle(const char *o, const char *m, const char *bl, int w)
    113113        {
    114                 other_mgr->send(o, m, bl, w);
     114                other_manager->send(o, m, bl, w);
    115115        }
    116116};
Note: See TracChangeset for help on using the changeset viewer.