blob: 9cb80386c0a51ae15bff1b52a8177012419499ee (
about) (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
/*
identifier.hh -- part of LilyPond
(c) 1996 Han-Wen Nienhuys
*/
#ifndef IDENTIFIER_HH
#define IDENTIFIER_HH
#include "proto.hh"
#include "string.hh"
struct Identifier
{
void *data;
String name;
Identifier(String n) ;
virtual ~Identifier();
virtual Staff * staff() { assert(false); }
virtual Voice * voice() { assert(false); }
};
struct Staff_id : Identifier {
Staff_id(String s, Staff*st):Identifier(s) { data = st; }
virtual Staff* staff() { return (Staff*) data; }
~Staff_id();
};
struct Voice_id : Identifier {
Voice_id(String s, Voice*st):Identifier(s) { data = st; }
virtual Voice * voice() { return (Voice*)data; }
~Voice_id();
};
#endif // IDENTIFIER_HH
|