|
From: Crossfire C. r. messages.
<cro...@li...> - 2015-02-22 19:25:30
|
Revision: 19792
http://sourceforge.net/p/crossfire/code/19792
Author: ryo_saeba
Date: 2015-02-22 19:25:27 +0000 (Sun, 22 Feb 2015)
Log Message:
-----------
Some documentation.
Modified Paths:
--------------
server/trunk/utils/cre/ScriptFile.h
server/trunk/utils/cre/ScriptFileManager.h
Modified: server/trunk/utils/cre/ScriptFile.h
===================================================================
--- server/trunk/utils/cre/ScriptFile.h 2015-02-22 19:22:11 UTC (rev 19791)
+++ server/trunk/utils/cre/ScriptFile.h 2015-02-22 19:25:27 UTC (rev 19792)
@@ -5,6 +5,7 @@
class CREMapInformation;
+/** Information about an event hook, linked to a script file. */
class HookInformation
{
public:
@@ -26,6 +27,7 @@
QString myEventName;
};
+/** Information about a script file. */
class ScriptFile
{
public:
@@ -34,6 +36,11 @@
void addHook(HookInformation* hook);
bool forMap(CREMapInformation* map) const;
+ /**
+ * Remove hooks linked to a map.
+ * @param map map to remove scripts of.
+ * @return true if this script has no more hooks, false else.
+ */
bool removeMap(CREMapInformation* map);
QList<HookInformation*> hooks() const;
const QString& path() const;
Modified: server/trunk/utils/cre/ScriptFileManager.h
===================================================================
--- server/trunk/utils/cre/ScriptFileManager.h 2015-02-22 19:22:11 UTC (rev 19791)
+++ server/trunk/utils/cre/ScriptFileManager.h 2015-02-22 19:25:27 UTC (rev 19792)
@@ -6,6 +6,7 @@
class ScriptFile;
class CREMapInformation;
+/** Manage scripts for items. */
class ScriptFileManager
{
public:
@@ -13,7 +14,18 @@
virtual ~ScriptFileManager();
QList<ScriptFile*> scriptsForMap(CREMapInformation* map);
+
+ /**
+ * Get information about a script path.
+ * @param path full script path.
+ * @return information about the script, never NULL.
+ */
ScriptFile* getFile(const QString& path);
+
+ /**
+ * Remove scripts linked to a map.
+ * @param map map to remove scripts of.
+ */
void removeMap(CREMapInformation* map);
private:
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|