-
Notifications
You must be signed in to change notification settings - Fork 0
/
transition_triggers.hpp
41 lines (29 loc) · 1.03 KB
/
transition_triggers.hpp
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
37
38
39
40
41
#ifndef SCHLAZICONTROL_TRANSITION_TRIGGERS_HPP
#define SCHLAZICONTROL_TRANSITION_TRIGGERS_HPP
#include <map>
#include <string>
#include <vector>
#include "transition.hpp"
namespace sc {
class Connection;
class Manager;
class PropertyNode;
namespace triggers {
class Action;
struct State;
} // namespace triggers
class TriggersTransition final
: public Transition
{
public:
TriggersTransition( std::string&& id, Manager& manager, PropertyNode const& properties );
virtual std::unique_ptr< TransitionInstance > instantiate() const override;
bool acceptsChannels( std::size_t channels ) const { return channels == 1; }
std::size_t emitsChannels( std::size_t channels ) const { return 1; }
void transform( triggers::State& state, Connection& connection, ChannelBuffer& values ) const;
private:
Manager& manager_;
std::vector< triggers::Action > actions_;
};
} // namespace sc
#endif // SCHLAZICONTROL_TRANSITION_TRIGGERS_HPP