| 134 | } |
| 135 | |
| 136 | void MacroConditionWebsocket::SetConnection(const std::string &connectionName) |
| 137 | { |
| 138 | _connection = GetWeakConnectionByName(connectionName); |
| 139 | if (_type == Type::REQUEST) { |
| 140 | // This should not really happen, but let's be safe |
| 141 | return; |
| 142 | } |
| 143 | |
| 144 | auto connection = _connection.lock(); |
| 145 | if (!connection) { |
| 146 | return; |
| 147 | } |
| 148 | _messageBuffer = connection->RegisterForEvents(); |
| 149 | } |
| 150 | |
| 151 | std::weak_ptr<WSConnection> MacroConditionWebsocket::GetConnection() const |
| 152 | { |
no test coverage detected