Files
Webcam/include/engine/script/script_binding_interface.h
2026-06-22 11:49:35 +02:00

43 lines
1.0 KiB
C++

/* -----------------------------------------------------------------------------
GSFramework
Copyright 2001-2013 Emmanuel Julien. All Rights Reserved.
----------------------------------------------------------------------------- */
#ifndef __SCRIPTBINDINGINTERFACE__
#define __SCRIPTBINDINGINTERFACE__
#include "plugin/plugin_manager.h"
namespace GS {
namespace Script {
class IVM;
/// Interface to provide additional script binding to a VM.
struct IScriptBinding
{
/// Return the plugin class.
static const char *GetPluginClass() { return "ScriptBinding"; }
/*!
@short Return the plugin version.
@note This version number must be increased whenever a modification
is made to the base interface in order to prevent an incompatible
plugin from being loaded.
*/
static uint GetPluginVersion() { return 1; }
/// Register the new script binding code into the VM.
virtual void RegisterBinding(IVM &) = 0;
};
typedef PluginManager <IScriptBinding> BindingPluginManager;
} // Script
} // GS
#endif // __SCRIPTBINDINGINTERFACE__