106 ,
public Nano::Observer
115 const QString& name()
const noexcept;
120 virtual DeviceResources usedResources()
const noexcept;
122 virtual void disconnect();
123 virtual bool reconnect() = 0;
126 virtual bool connected()
const;
127 W_INVOKABLE(connected)
147 void addToListening(
const std::vector<State::Address>&);
149 std::vector<State::Address> listening()
const;
151 std::vector<State::Address> listeningRequests()
const;
153 void restoreListening();
156 virtual void updateAddress(
160 void sendMessage(
const State::Address& addr,
const ossia::value& v);
166 bool isLogging()
const;
167 void setLogging(DeviceLogging);
169 virtual ossia::net::device_base* getDevice()
const = 0;
171 virtual bool isLearning()
const;
172 virtual void setLearning(
bool);
174 virtual QMimeData* mimeData()
const;
175 virtual void setupContextMenu(QMenu&)
const;
177 void nodeCreated(
const ossia::net::node_base&);
178 void nodeRemoving(
const ossia::net::node_base&);
179 void nodeRenamed(
const ossia::net::node_base&, std::string);
180 void addressCreated(
const ossia::net::parameter_base&);
181 void addressUpdated(
const ossia::net::node_base&, ossia::string_view key);
182 void addressRemoved(
const ossia::net::parameter_base& addr);
184 Nano::Signal<void(
const State::Address&,
const ossia::value&)> valueUpdated;
189 E_SIGNAL(SCORE_LIB_DEVICE_EXPORT, pathAdded, arg_1)
193 E_SIGNAL(SCORE_LIB_DEVICE_EXPORT, pathUpdated, arg_1, arg_2)
195 E_SIGNAL(SCORE_LIB_DEVICE_EXPORT, pathRemoved, arg_1)
198 void namespaceUpdated() E_SIGNAL(SCORE_LIB_DEVICE_EXPORT, namespaceUpdated)
201 void deviceChanged(ossia::net::device_base* old_dev, ossia::net::device_base* new_dev)
202 E_SIGNAL(SCORE_LIB_DEVICE_EXPORT, deviceChanged, old_dev, new_dev)
206 void logInbound(
const QString& arg_1)
const
207 E_SIGNAL(SCORE_LIB_DEVICE_EXPORT, logInbound, arg_1)
208 void logOutbound(
const QString& arg_1)
const
209 E_SIGNAL(SCORE_LIB_DEVICE_EXPORT, logOutbound, arg_1)
211 void connectionChanged(
bool arg_1)
const
212 E_SIGNAL(SCORE_LIB_DEVICE_EXPORT, connectionChanged, arg_1)
218 using callback_pair = std::pair<
219 ossia::net::parameter_base*,
220 ossia::callback_container<ossia::value_callback>::iterator>;
221 score::hash_map<State::Address, callback_pair> m_callbacks;
223 void removeListening_impl(ossia::net::node_base& node,
State::Address addr);
224 void removeListening_impl(
225 ossia::net::node_base& node,
State::Address addr, std::vector<State::Address>&);
226 void renameListening_impl(
const State::Address& parent,
const QString& newName);
227 void setLogging_impl(DeviceLogging)
const;
228 void enableCallbacks();
229 void disableCallbacks();
239 ossia::hash_set<State::Address> m_listeningRequests;
240 DeviceLogging m_logging = DeviceLogging::LogNothing;
241 bool m_callbacksEnabled =
false;
273 case ossia::parameter_type::MESSAGE:
274 case ossia::parameter_type::AUDIO:
276 case ossia::parameter_type::MIDI:
277 case ossia::parameter_type::TEXTURE:
278 case ossia::parameter_type::GEOMETRY:
bool hasEditableValue(ossia::parameter_type t) noexcept
Whether a parameter of that kind carries a value the explorer can show and edit.
Definition DeviceInterface.hpp:269
constexpr bool carries(NodeKind set, NodeKind wanted) noexcept
Whether every kind in wanted is in set.
Definition DeviceInterface.hpp:74