Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 61 lines (47 sloc) 1.753 kb
4b71bbe @mhroth Add LGPL license to remaining files.
authored
1 /*
a17043f @mhroth add MessageMetro. Note that PdGraph does not support cancelMessage yet.
authored
2 * Copyright 2009,2010 Reality Jockey, Ltd.
4b71bbe @mhroth Add LGPL license to remaining files.
authored
3 * info@rjdj.me
4 * http://rjdj.me/
5 *
6 * This file is part of ZenGarden.
7 *
8 * ZenGarden is free software: you can redistribute it and/or modify
9 * it under the terms of the GNU Lesser General Public License as published by
10 * the Free Software Foundation, either version 3 of the License, or
11 * (at your option) any later version.
12 *
13 * ZenGarden is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU Lesser General Public License for more details.
17 *
18 * You should have received a copy of the GNU Lesser General Public License
19 * along with ZenGarden. If not, see <http://www.gnu.org/licenses/>.
20 *
21 */
22
abb33ec First commit of current source.
Martin Roth authored
23 #ifndef _MESSAGE_METRO_H_
24 #define _MESSAGE_METRO_H_
25
a17043f @mhroth add MessageMetro. Note that PdGraph does not support cancelMessage yet.
authored
26 #include "MessageObject.h"
abb33ec First commit of current source.
Martin Roth authored
27
a17043f @mhroth add MessageMetro. Note that PdGraph does not support cancelMessage yet.
authored
28 class PdGraph;
29
30 /** [metro], [metro float] */
31 class MessageMetro : public MessageObject {
abb33ec First commit of current source.
Martin Roth authored
32
33 public:
7329847 @mhroth Add static factory method to all objects in order to create an object…
authored
34 static MessageObject *newObject(PdMessage *initMessage, PdGraph *graph);
41ba30e @mhroth Clean up code of MessageMetro in order to make it more presentable an…
authored
35 MessageMetro(PdMessage *initMessage, PdGraph *graph);
abb33ec First commit of current source.
Martin Roth authored
36 ~MessageMetro();
a17043f @mhroth add MessageMetro. Note that PdGraph does not support cancelMessage yet.
authored
37
7329847 @mhroth Add static factory method to all objects in order to create an object…
authored
38 static const char *getObjectLabel();
3f6a39c @Kyew Rewrote header functions as inline, add toString to all objects
Kyew authored
39 std::string toString();
728349a @mhroth remove MessageObject::sendScheduledObject in favour of making Message…
authored
40
41 void sendMessage(int outletIndex, PdMessage *message);
abb33ec First commit of current source.
Martin Roth authored
42
43 private:
a17043f @mhroth add MessageMetro. Note that PdGraph does not support cancelMessage yet.
authored
44 void processMessage(int inletIndex, PdMessage *message);
45
41ba30e @mhroth Clean up code of MessageMetro in order to make it more presentable an…
authored
46 /* Cancels the current <code>pendingMessage</code>. */
47 void stopMetro();
48
49 /** @param timestamp The time at which the metro should be started. */
50 void startMetro(double timestamp);
a17043f @mhroth add MessageMetro. Note that PdGraph does not support cancelMessage yet.
authored
51
52 PdMessage *pendingMessage;
53 double intervalInMs;
abb33ec First commit of current source.
Martin Roth authored
54 };
55
3f6a39c @Kyew Rewrote header functions as inline, add toString to all objects
Kyew authored
56 inline const char *MessageMetro::getObjectLabel() {
57 return "metro";
58 }
59
abb33ec First commit of current source.
Martin Roth authored
60 #endif // _MESSAGE_METRO_H_
Something went wrong with that request. Please try again.