core/systems/PluginSys.h
changeset 290 da8de49409e8
parent 282 cd7c334f7ae0
child 298 07f6b2fe8468
     1.1 --- a/core/systems/PluginSys.h	Sat Jan 13 04:28:13 2007 +0000
     1.2 +++ b/core/systems/PluginSys.h	Mon Jan 15 00:56:39 2007 +0000
     1.3 @@ -94,7 +94,7 @@
     1.4  	virtual const sp_plugin_t *GetPluginStructure() const;
     1.5  	virtual IPluginFunction *GetFunctionByName(const char *public_name);
     1.6  	virtual IPluginFunction *GetFunctionById(funcid_t func_id);
     1.7 -	virtual IdentityToken_t *GetIdentity();
     1.8 +	virtual IdentityToken_t *GetIdentity() const;
     1.9  public:
    1.10  	/**
    1.11  	 * Creates a plugin object with default values.
    1.12 @@ -146,6 +146,16 @@
    1.13  	 * Calls the OnPluginUnload function.
    1.14  	 */
    1.15  	void Call_OnPluginUnload();
    1.16 +
    1.17 +	/**
    1.18 +	* Toggles debug mode in the plugin
    1.19 +	*/
    1.20 +	bool ToggleDebugMode(bool debug);
    1.21 +
    1.22 +	/**
    1.23 +	* Returns true if a plugin is usable.
    1.24 +	*/
    1.25 +	bool IsRunnable() const;
    1.26  public:
    1.27  	time_t HasUpdatedFile();
    1.28  
    1.29 @@ -242,7 +252,7 @@
    1.30  	/** 
    1.31  	 * Returns whether anything loaded will be a late load.
    1.32  	 */
    1.33 -	bool IsLateLoadTime();
    1.34 +	bool IsLateLoadTime() const;
    1.35  
    1.36  	/**
    1.37  	 * Adds natives from core into the native pool.
    1.38 @@ -253,6 +263,11 @@
    1.39  	 * Converts a Handle to an IPlugin if possible.
    1.40  	 */
    1.41  	IPlugin *PluginFromHandle(Handle_t handle, HandleError *err);
    1.42 +
    1.43 +	/**
    1.44 +	* Finds a plugin based on its index. (starts on index 1)
    1.45 +	*/
    1.46 +	CPlugin *GetPluginByOrder(int num);
    1.47  private:
    1.48  	/**
    1.49  	 * Recursively loads all plugins in the given directory.