]> git.tdb.fi Git - libs/datafile.git/blobdiff - source/loader.h
Don't throw on empty files
[libs/datafile.git] / source / loader.h
index 5c8726a179683c841e6439e57fd3cfa4772394e2..126de575ba027fb0cd241ee4a8f5beb0654550b7 100644 (file)
@@ -56,14 +56,19 @@ private:
 
        typedef std::map<ActionKey, LoaderAction *> ActionMap;
 
-       ActionMap       actions;
+       ActionMap actions;
        const Statement *cur_st;
-
+       bool sub_loaded;
 protected:
-       Loader(): cur_st(0) { }
+       bool allow_pointer_reload;
+       bool check_sub_loads;
+
+       Loader();
 public:
        virtual ~Loader();
 
+       bool is_pointer_reload_allowed() const { return allow_pointer_reload; }
+
        /** Loads statements from a parser. */
        void load(Parser &p);
 
@@ -156,8 +161,7 @@ protected:
 
 
 /**
-Provides the basic functionality of an object loader.  Deriving from this
-allows loading values directly into member variables of the objects.
+Deprecated.  See ObjectLoader in objectloader.h.
 */
 template<typename O>
 class BasicLoader: public Loader
@@ -175,8 +179,7 @@ public:
 
 
 /**
-Provides functionality for loading objects with a Collection.  Deriving from
-this allows loading pointers to objects in the collection automatically.
+Deprecated.  See CollectionObjectLoader in objectloader.h.
 */
 template<typename O, typename C>
 class BasicLoader2: public BasicLoader<O>