/** SGX

The   sss    gggg x   x   
     s      g      x x    Engine
      sss   g  gg   x
         s  g   g  x x          Copyright 1995-2009.
     ssss    gggg x   x         Steven Goodwin. All Rights Reserved.
    
This version has been released under the GNU Public License v2.0.

Please see the license files for details.

File: sgx/include/sgx/scripting/scriptmanager.hpp

*/

#ifndef SGX_SCRIPTING_SCRIPTING_MANAGER_HPP
#define SGX_SCRIPTING_SCRIPTING_MANAGER_HPP	1

#include "sgx/core/types/types.hpp"
#include "sgx/core/stl/stl.hpp"

typedef sgxMap<sgxString, CScriptingEngine *> ScriptMap;

class CSGXScriptingManager {
public:
    static  CSGXScriptingManager    *get();

	tBOOL		registerObject(CScriptingEngine *pEngine, const sgxString &name);
	CScriptState *CreateInstance();
	CScriptState *CreateInstance(const sgxString &name);


protected:
    static  CSGXScriptingManager    *ms_pSingleton;
    CSGXScriptingManager();

private:
    virtual ~CSGXScriptingManager();
    ScriptMap					  m_ScriptEngines;

};

#endif /* SGX_SCRIPTING_SCRIPTING_MANAGER_HPP */
