Loading...
Searching...
No Matches
LocalTree::ScriptableTreeBase Class Referenceabstract

Publishes the scriptable namespace and maps addresses to objects and back. More...

Inheritance diagram for LocalTree::ScriptableTreeBase:
score::DocumentPlugin LocalTree::DocumentPlugin

Detailed Description

Publishes the scriptable namespace and maps addresses to objects and back.

Public Member Functions

virtual ossia::net::device_base & device () const noexcept=0
 
virtual std::shared_ptr< const ScriptableSnapshot > snapshot () const noexcept=0
 Copy of the namespace for scripts on other threads; GUI thread only.
 
void snapshotChanged ()
 
virtual QObject * objectAt (const ossia::net::node_base &node, QString &member) const noexcept=0
 The object a published node stands for; member receives which of its parameters.
 
virtual ossia::net::node_base * nodeOf (const QObject &object, const QString &member) const noexcept=0
 
virtual std::vector< QObject * > referrers (const QObject &target) const =0
 The states, ports, events and syncs holding an address anchored to the object.
 
virtual std::vector< QObject * > targets (const QObject &referrer) const =0
 The objects the addresses of a state, port, event or sync are anchored to.
 
virtual void follow (QObject &referrer)=0
 
virtual ossia::net::parameter_base * reserve (const ::State::Address &address, const ossia::value &sample)=0
 
void setEmphasized (std::vector< const QObject * > objects)
 Objects the selection refers to or that refer to it; drawn emphasized.
 
bool emphasized (const QObject &object) const noexcept
 
void emphasisChanged ()
 
void published (QObject *object)
 Emitted when a namespace node starts standing for the object.
 
void referencesChanged (QObject *referrer)
 The referrer's references may have broken or resolved; null means all. Coalesced.
 
void executionStarted ()
 
void executionStopped ()
 Emitted when the execution has released the published controls.
 
virtual bool hasPlayedValues () const noexcept=0
 Whether the last run wrote control values that only the execution received.
 
virtual void keepPlayedValues ()=0
 Stores these values in the document, as Record playback would.
 
void playedValuesChanged ()
 
Recall recall () const noexcept
 Read from any thread.
 
uint32_t runsEnded () const noexcept
 Read from any thread.
 
Recall recallAt (Recall recall, uint32_t run) const noexcept
 A write from a run that has ended since counts as written at its stop.
 
- Public Member Functions inherited from score::DocumentPlugin
 DocumentPlugin (const score::DocumentContext &, const QString &name, QObject *parent)
 
const score::DocumentContext & context () const
 
template<typename Impl >
 DocumentPlugin (const score::DocumentContext &ctx, Impl &vis, QObject *parent)
 
virtual void on_documentClosing ()
 

Protected Attributes

std::atomic< Recall > m_recall {Recall::None}
 
std::atomic< uint32_t > m_runsEnded {}
 
- Protected Attributes inherited from score::DocumentPlugin
const score::DocumentContext & m_context
 

Member Function Documentation

◆ follow()

virtual void LocalTree::ScriptableTreeBase::follow ( QObject &  referrer)
pure virtual

Re-derives the referrer's local addresses from their anchors and anchors the others by name; pasted copies publish under new names.

Implemented in LocalTree::DocumentPlugin.

◆ hasPlayedValues()

virtual bool LocalTree::ScriptableTreeBase::hasPlayedValues ( ) const
pure virtualnoexcept

Whether the last run wrote control values that only the execution received.

Implemented in LocalTree::DocumentPlugin.

◆ keepPlayedValues()

virtual void LocalTree::ScriptableTreeBase::keepPlayedValues ( )
pure virtual

Stores these values in the document, as Record playback would.

Implemented in LocalTree::DocumentPlugin.

◆ objectAt()

virtual QObject * LocalTree::ScriptableTreeBase::objectAt ( const ossia::net::node_base &  node,
QString &  member 
) const
pure virtualnoexcept

The object a published node stands for; member receives which of its parameters.

Implemented in LocalTree::DocumentPlugin.

◆ referrers()

virtual std::vector< QObject * > LocalTree::ScriptableTreeBase::referrers ( const QObject &  target) const
pure virtual

The states, ports, events and syncs holding an address anchored to the object.

Implemented in LocalTree::DocumentPlugin.

◆ reserve()

virtual ossia::net::parameter_base * LocalTree::ScriptableTreeBase::reserve ( const ::State::Address &  address,
const ossia::value &  sample 
)
pure virtual

Parameter to send to for the address of a dynamic port not created yet; the port takes it over when it appears.

Implemented in LocalTree::DocumentPlugin.

◆ snapshot()

virtual std::shared_ptr< const ScriptableSnapshot > LocalTree::ScriptableTreeBase::snapshot ( ) const
pure virtualnoexcept

Copy of the namespace for scripts on other threads; GUI thread only.

Implemented in LocalTree::DocumentPlugin.

◆ targets()

virtual std::vector< QObject * > LocalTree::ScriptableTreeBase::targets ( const QObject &  referrer) const
pure virtual

The objects the addresses of a state, port, event or sync are anchored to.

Implemented in LocalTree::DocumentPlugin.


The documentation for this class was generated from the following files: