All pastes #637602 Raw Edit

Something

public text v1 · immutable
#637602 ·published 2007-07-29 01:36 UTC
rendered paste body
#ifndef ADMIN_MANAGER_H_INCLUDED
#define ADMIN_MANAGER_H_INCLUDED

#include "UWD.h"
#include "RakNetTypes.h"

//#include <string>
//#include <boost/lexical_cast.hpp>

namespace UWD
{

    typedef std::map<SystemAddress, AdminData> TAdminIDMap;

    /*!
    * \brief
    * Singleton AdminManager - manages administrator connections
    *
    */
    class AdminManager: public InstanceManager, public PacketHandler
    {
        private:
            // Hide the Constructorz!
            /*! \brief AdminManager constructor.*/
            AdminManager();
            ~AdminManager();

            AdminManager& operator=(AdminManager&);  // Disallowed
            AdminManager(const AdminManager&);       // Disallowed

            /*! \brief
            * Map where Key is the SystemAddress of a client, and value is the PlayerData struct for that client.
            * This is used as a quick lookup to find information on a certain client.
            */
            TAdminIDMap adminMap;

        public:
            static AdminManager& getSingleton();

            void handlePacket(Packet* packetToHandle);

    };
}


#endif // ADMIN_MANAGER_H_INCLUDED