annotate nodejs/observer.m4 @ 650:123e7eeff10c

Generate JS binding for a function
author Thinker K.F. Li <thinker@branda.to>
date Thu, 29 Jul 2010 13:07:25 +0800
parents 2030e5d9f7f7
children aa52883534fc
rev   line source
648
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
1 STRUCT([event], [event_t],
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
2 [INT([event]), OBJ([tgt], [subject]),
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
3 OBJ([cur_tgt], [subject]), INT([flags])], [])
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
4
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
5 STRUCT([observer], [observer_t],
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
6 [INT([type])], [])
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
7
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
8 STRUCT([subject], [subject_t], [],
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
9 [METHOD([add_event_observer], [subject_add_event_observer],
649
2030e5d9f7f7 Support return value for methodes of JS binding
Thinker K.F. Li <thinker@branda.to>
parents: 648
diff changeset
10 (INT([type]), FUNC([handler])), 2,
2030e5d9f7f7 Support return value for methodes of JS binding
Thinker K.F. Li <thinker@branda.to>
parents: 648
diff changeset
11 [OBJ([observer], [observer_t])]),
648
e13dbfd37eab JS binding generator and observer definition with the generator
Thinker K.F. Li <thinker@branda.to>
parents:
diff changeset
12 METHOD([remove_observer], [subject_remove_observer],
649
2030e5d9f7f7 Support return value for methodes of JS binding
Thinker K.F. Li <thinker@branda.to>
parents: 648
diff changeset
13 (OBJ([observer], [observer_t])), 1, [])])
650
123e7eeff10c Generate JS binding for a function
Thinker K.F. Li <thinker@branda.to>
parents: 649
diff changeset
14
123e7eeff10c Generate JS binding for a function
Thinker K.F. Li <thinker@branda.to>
parents: 649
diff changeset
15 FUNCTION([load], [my_load], [INT(sz), STR(name)], 2, [OBJ([test],[test_t])])