]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-0.0.71pre
authorfred <fred>
Tue, 1 Jul 1997 08:52:30 +0000 (08:52 +0000)
committerfred <fred>
Tue, 1 Jul 1997 08:52:30 +0000 (08:52 +0000)
lily/acceptor.cc [new file with mode: 0644]
lily/include/acceptor.hh [new file with mode: 0644]

diff --git a/lily/acceptor.cc b/lily/acceptor.cc
new file mode 100644 (file)
index 0000000..0164b83
--- /dev/null
@@ -0,0 +1,16 @@
+/*
+  acceptor.cc -- implement Acceptor
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+#include "acceptor.hh"
+Acceptor::Acceptor()
+{
+    iterator_count_  = 0;
+}
+
+IMPLEMENT_STATIC_NAME(Acceptor);
+IMPLEMENT_IS_TYPE_B(Acceptor);
diff --git a/lily/include/acceptor.hh b/lily/include/acceptor.hh
new file mode 100644 (file)
index 0000000..f298951
--- /dev/null
@@ -0,0 +1,40 @@
+/*
+  acceptor.hh -- declare Acceptor
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+*/
+
+
+#ifndef ACCEPTOR_HH
+#define ACCEPTOR_HH
+
+#include "string.hh"
+#include "lily-proto.hh"
+#include "interpreter.hh"
+#include "virtual-methods.hh"
+
+class Acceptor {
+public:
+    String id_str_;
+    
+    int iterator_count_;
+    
+    virtual Interpreter * interpreter_l() { return 0; }
+
+    /// Score_register = 0, Staff_registers = 1, etc)
+    virtual int depth_i()const=0;
+    virtual Acceptor *find_get_acceptor_l(String name, String id)=0;
+    virtual Acceptor *ancestor_l(int l=1)=0;
+    virtual ~Acceptor(){}
+    NAME_MEMBERS();
+    Acceptor();
+    virtual Acceptor *get_default_interpreter()=0;
+};
+
+class Interpreter : public virtual Acceptor {
+public:
+    virtual bool interpret_request_b(Request*) { return false;}
+};
+#endif // ACCEPTOR_HH