|
|
void | accept (NetworkVisitor &visor) |
| | Accept a NetworkVisitor, the visitor will visit each Processor of the Network in an undefined order. The Visitor will then visit each processors Properties and so on.
|
| |
| void | addConnection (const PortConnection &connection) |
| | Add a PortConnection to the ProcessorNetwork.
|
| |
| void | addConnection (Outport *sourcePort, Inport *destPort) |
| | Add a PortConnection to the ProcessorNetwork.
|
| |
| void | addLink (const PropertyLink &link) |
| | Create and add Property Link to the network.
|
| |
| void | addLink (Property *source, Property *destination) |
| | Create and add Property Link to the network.
|
| |
| Processor * | addProcessor (std::shared_ptr< Processor > processor) |
| | Adds a Processor to the ProcessorNetwork.
|
| |
| template<typename T , class = typename std::enable_if_t<std::is_base_of_v<Processor, T>, void>> |
| T * | addProcessor (std::shared_ptr< T > processor) |
| | Adds a Processor to the ProcessorNetwork. s.
|
| |
| bool | canConnect (const Outport *sourcePort, const Inport *destPort) const |
| |
|
bool | canLink (const Property *source, const Property *destination) const |
| | Check if source can be linked to destination.
|
| |
| void | clear () |
| |
| auto | connectionRange () const |
| |
| auto | connectionVecRange () const |
| |
| virtual void | deserialize (Deserializer &d) override |
| |
| template<typename T , class = typename std::enable_if_t<std::is_base_of_v<Processor, T>, void>, typename... Args> |
| std::shared_ptr< T > | emplaceProcessor (Args &&... args) |
| | Emplace a Processor into the ProcessorNetwork.
|
| |
|
bool | empty () const |
| |
|
void | evaluateLinksFromProperty (Property *) |
| |
| template<typename C > |
| void | forEachConnection (C callback) |
| | Apply a function to each connection in the network.
|
| |
| template<typename C > |
| void | forEachLink (C callback) |
| | Apply a function to each property link in the network.
|
| |
| template<typename C > |
| void | forEachProcessor (C callback) |
| | Apply a function to each processor in the network.
|
| |
|
InviwoApplication * | getApplication () const |
| |
|
const std::vector< PortConnection > & | getConnections () const |
| | Get all connections in the network.
|
| |
|
ProcessorNetworkEvaluator * | getEvaluator () const |
| |
|
const std::string & | getIdentifier () const |
| |
| Inport * | getInport (std::string_view path) const |
| | Get Inport by path.
|
| |
| std::vector< PropertyLink > | getLinks () const |
| | Get all connections in the network.
|
| |
|
std::vector< PropertyLink > | getLinksBetweenProcessors (Processor *p1, Processor *p2) |
| |
| Outport * | getOutport (std::string_view path) const |
| | Get Outport by path.
|
| |
| Port * | getPort (std::string_view path) const |
| | Get Port by path.
|
| |
| Processor * | getProcessorByIdentifier (std::string_view identifier) const |
| | Returns the Processor from the ProcessorNetwork, which has the given identifier.
|
| |
| std::vector< Processor * > | getProcessors () const |
| | Get all processors in the network.
|
| |
| template<class T > |
| std::vector< T * > | getProcessorsByType () const |
| | Returns a vector of Processors which are of type T.
|
| |
|
std::vector< Property * > | getPropertiesLinkedTo (Property *property) |
| |
| Property * | getProperty (std::string_view path) const |
| | Get Property by path.
|
| |
| bool | isConnected (const PortConnection &connection) const |
| | Checks whether two port are connected.
|
| |
| bool | isConnected (Outport *sourcePort, Inport *destPort) const |
| | Checks whether two port are connected.
|
| |
|
bool | isDeserializing () const |
| |
|
bool | isEmpty () const |
| |
|
bool | isInvalidating () const |
| |
| bool | isLinked (const PropertyLink &link) const |
| |
| bool | isLinked (Property *source, Property *destination) const |
| |
| bool | isLinkedBidirectional (Property *source, Property *destination) const |
| |
|
bool | isLinking () const |
| |
|
bool | islocked () const |
| |
| bool | isPortInNetwork (Port *port) const |
| | Check if port is owned by a processor in this ProcessorNetwork.
|
| |
|
bool | isPropertyInNetwork (Property *prop) const |
| |
| auto | linkRange () const |
| |
|
void | lock () |
| |
|
ProcessorNetwork & | operator= (const ProcessorNetwork &)=delete |
| |
|
ProcessorNetwork & | operator= (ProcessorNetwork &&)=delete |
| |
|
| ProcessorNetwork (const ProcessorNetwork &)=delete |
| |
|
| ProcessorNetwork (InviwoApplication *application, std::string_view identifier="network") |
| |
|
| ProcessorNetwork (ProcessorNetwork &&)=delete |
| |
| auto | processorRange () const |
| |
| void | removeConnection (const PortConnection &connection) |
| | Removes a PortConnection from the ProcessorNetwork.
|
| |
| void | removeConnection (Outport *sourcePort, Inport *destPort) |
| | Removes a PortConnection from the ProcessorNetwork.
|
| |
| void | removeLink (const PropertyLink &link) |
| |
| void | removeLink (Property *source, Property *destination) |
| |
|
int | runningBackgroundJobs () const |
| |
| virtual void | serialize (Serializer &s) const override |
| |
|
void | setEvaluator (ProcessorNetworkEvaluator *evaluator) |
| |
|
void | setIdentifier (std::string_view identifier) |
| |
|
size_t | size () const |
| |
|
void | unlock () |
| |
|
void | notifyObserversProcessorBackgroundJobsChanged (Processor *p, int diff, int total) |
| |
|
void | notifyObserversProcessorNetworkChanged () |
| |
|
void | notifyObserversProcessorNetworkDidAddConnection (const PortConnection &connection) |
| |
|
void | notifyObserversProcessorNetworkDidAddLink (const PropertyLink &propertyLink) |
| |
|
void | notifyObserversProcessorNetworkDidAddProcessor (Processor *processor) |
| |
|
void | notifyObserversProcessorNetworkDidRemoveConnection (const PortConnection &connection) |
| |
|
void | notifyObserversProcessorNetworkDidRemoveLink (const PropertyLink &propertyLink) |
| |
|
void | notifyObserversProcessorNetworkDidRemoveProcessor (Processor *processor) |
| |
|
void | notifyObserversProcessorNetworkEvaluateRequest () |
| |
|
void | notifyObserversProcessorNetworkUnlocked () |
| |
|
void | notifyObserversProcessorNetworkWillAddConnection (const PortConnection &connection) |
| |
|
void | notifyObserversProcessorNetworkWillAddLink (const PropertyLink &propertyLink) |
| |
|
void | notifyObserversProcessorNetworkWillAddProcessor (Processor *processor) |
| |
|
void | notifyObserversProcessorNetworkWillRemoveConnection (const PortConnection &connection) |
| |
|
void | notifyObserversProcessorNetworkWillRemoveLink (const PropertyLink &propertyLink) |
| |
|
void | notifyObserversProcessorNetworkWillRemoveProcessor (Processor *processor) |
| |
|
void | addObserver (ProcessorNetworkObserver *observer) |
| |
|
bool | isObservedBy (ProcessorNetworkObserver *observer) const |
| |
| | Observable (const Observable< ProcessorNetworkObserver > &other) |
| |
| | Observable (Observable< ProcessorNetworkObserver > &&other) noexcept |
| |
| Observable< ProcessorNetworkObserver > & | operator= (const Observable< ProcessorNetworkObserver > &other) |
| |
| Observable< ProcessorNetworkObserver > & | operator= (Observable< ProcessorNetworkObserver > &&other) noexcept |
| |
|
void | removeObserver (ProcessorNetworkObserver *observer) |
| |
| virtual void | startBlockingNotifications () override final |
| |
| virtual void | stopBlockingNotifications () override final |
| |
|
virtual void | onProcessorAboutToProcess (Processor *) |
| |
| virtual void | onProcessorActiveConnectionsChanged (Processor *) |
| |
|
virtual void | onProcessorFinishedProcess (Processor *) |
| |
|
virtual void | onProcessorPortAdded (Processor *, Port *) |
| |
| virtual void | onProcessorProgressChanged (Processor *, std::optional< double >) |
| | Called when a processor progress has changed.
|
| |
| virtual void | onProcessorReadyChanged (Processor *) |
| |
| virtual void | onProcessorSinkChanged (Processor *) |
| |
| virtual void | onProcessorSourceChanged (Processor *) |
| |
|
| Observer (const Observer &other) |
| |
|
| Observer (Observer &&other) |
| |
|
Observer & | operator= (const Observer &other) |
| |
|
Observer & | operator= (Observer &&other) |
| |
| void | removeObservation (ObservableInterface *observable) |
| |
|
void | removeObservations () |
| |
| virtual | ~Observer () |
| |
|
virtual void | onDidAddProperty (Property *property, size_t index) |
| |
|
virtual void | onDidRemoveProperty (PropertyOwner *owner, Property *property, size_t index) |
| |
| virtual void | onWillAddProperty (PropertyOwner *owner, Property *property, size_t index) |
| |
This class manages the current processor network. It can be thought of as a container of Processor instances, which Port instances are connected through PortConnection instances, and which Property instances are linked through ProcessorLink instances. To manage Processors, PortConnections and ProcessorLinks, add and remove methods are available for all these entities. The network should be only modified by using these methods. Typically, these methods are called by the NetworkEditor, which enables the user to edit ProcessorNetworks.
When the ProcessorNetwork has been changed, it is flagged as modified. This mechanism is used by the ProcessorNetworkEvaluator to identify if the ProcessorNetwork needs to be analyzed before processing.
In the model view controller design pattern, the ProcessorNetwork represents the model, which means that no graphical representations are generated for the added entities. Adding and removing of the graphical representations is done in the NetworkEditor.