- const std::string &get_source() const
- {
- if(!cur_st)
- throw InvalidState("get_source called without current statement");
- return cur_st->source;
- }
-
- virtual void finish() { }
-};
-
-
-/**
-Provides the basic functionality of an object loader. Deriving from this
-allows loading values directly into member variables of the objects.
-*/
-template<typename O>
-class BasicLoader: public Loader
-{
-public:
- typedef O Object;
-
-protected:
- O &obj;
-
-public:
- BasicLoader(O &o): obj(o) { }
- O &get_object() const { return obj; }
-};