--- /dev/null
+#ifndef MSP_GL_SL_MODULECACHE_H_
+#define MSP_GL_SL_MODULECACHE_H_
+
+#include <msp/datafile/collection.h>
+#include "syntax.h"
+
+namespace Msp {
+namespace GL {
+namespace SL {
+
+class ModuleCache
+{
+private:
+ DataFile::Collection *resources;
+ std::map<std::string, Module *> modules;
+ unsigned next_source;
+
+public:
+ ModuleCache(DataFile::Collection *);
+ ModuleCache(const ModuleCache &);
+ ModuleCache &operator=(const ModuleCache &);
+ ~ModuleCache();
+
+ const Module &add_module(const std::string &, const std::string &);
+ const Module &add_module(IO::Base &, const std::string &);
+ const Module &get_module(const std::string &);
+};
+
+} // namespace SL
+} // namespace GL
+} // namespace Msp
+
+#endif