Vuo  2.0.0
Public Member Functions | List of all members
VuoComposition Class Reference

Description

A collection of nodes and the cables connecting them.

Definition at line 26 of file VuoComposition.hh.

Public Member Functions

 VuoComposition (void)
 Creates an empty composition. More...
 
void setMetadata (VuoCompositionMetadata *metadata, bool takeOwnership)
 Assigns metadata to this composition. More...
 
VuoCompositionMetadatagetMetadata (void)
 Returns the metadata associated with this composition. More...
 
void setDirectory (string directory)
 Sets the directory containing the composition's .vuo source file. More...
 
string getDirectory (void)
 Returns the directory containing the composition's .vuo source file. More...
 
void addNode (VuoNode *node)
 Adds a node to the composition. More...
 
void removeNode (VuoNode *node)
 Removes a node from the composition. More...
 
set< VuoNode * > getNodes (void)
 Returns the nodes in this composition. More...
 
void addCable (VuoCable *cable)
 Adds a cable to the composition. More...
 
void removeCable (VuoCable *cable)
 Disconnects and removes a cable from the composition. More...
 
set< VuoCable * > getCables (void)
 Returns the cables in this composition. More...
 
void addComment (VuoComment *comment)
 Adds a comment to the composition. More...
 
void removeComment (VuoComment *comment)
 Removes a comment from the composition. More...
 
set< VuoComment * > getComments (void)
 Returns the comments in this composition. More...
 
void addPublishedInputPort (VuoPublishedPort *port, int index)
 Adds a published port to this composition's list of published input ports at the given index. More...
 
void addPublishedOutputPort (VuoPublishedPort *port, int index)
 Adds a published port to this composition's list of published output ports at the given index. More...
 
void removePublishedInputPort (int index)
 Removes the published port at the given index from this composition's list of published input ports. More...
 
void removePublishedOutputPort (int index)
 Removes the published port at the given index from this composition's list of published input ports. More...
 
vector< VuoPublishedPort * > getPublishedInputPorts (void)
 Returns the published input ports in this composition. More...
 
vector< VuoPublishedPort * > getPublishedOutputPorts (void)
 Returns the published output ports in this composition. More...
 
VuoPublishedPortgetPublishedInputPortWithName (string name)
 Returns the published input port with the given name, or null if none matches. More...
 
VuoPublishedPortgetPublishedOutputPortWithName (string name)
 Returns the published output port with the given name, or null if none matches. More...
 
int getIndexOfPublishedPort (VuoPublishedPort *port, bool isInput)
 Returns the index of the published port in the list of published input or output ports. More...
 
vector< VuoPublishedPort * > getProtocolAwarePublishedPortOrder (VuoProtocol *protocol, bool publishedInputs)
 Returns an ordered list of the composition's published input or output ports, with published ports belonging to the provided protocol listed first, followed by published ports that are not part of the protocol. More...
 
- Public Member Functions inherited from VuoBase< VuoCompilerComposition, VuoRendererComposition >
 VuoBase (string id)
 Creates a base class. More...
 
void setCompiler (VuoCompilerComposition *compiler)
 Sets the base class instance's compiler detail class instance. More...
 
VuoCompilerCompositiongetCompiler (void) const
 Returns the base class instance's compiler detail class instance. More...
 
bool hasCompiler (void) const
 Returns true if this base class instance has a compiler detail. More...
 
void setRenderer (VuoRendererComposition *renderer)
 Sets the base class instance's renderer detail class instance. More...
 
VuoRendererCompositiongetRenderer (void) const
 Returns the base class instance's renderer detail class instance. More...
 
bool hasRenderer (void) const
 Returns true if this base class instance has a renderer detail. More...
 

Constructor & Destructor Documentation

◆ VuoComposition()

VuoComposition::VuoComposition ( void  )

Creates an empty composition.

Definition at line 20 of file VuoComposition.cc.

Member Function Documentation

◆ addCable()

void VuoComposition::addCable ( VuoCable cable)

Adds a cable to the composition.

The caller is responsible for adding the nodes on either end of the cable to the composition.

Definition at line 104 of file VuoComposition.cc.

◆ addComment()

void VuoComposition::addComment ( VuoComment comment)

Adds a comment to the composition.

Definition at line 131 of file VuoComposition.cc.

◆ addNode()

void VuoComposition::addNode ( VuoNode node)

Adds a node to the composition.

Definition at line 76 of file VuoComposition.cc.

◆ addPublishedInputPort()

void VuoComposition::addPublishedInputPort ( VuoPublishedPort port,
int  index 
)

Adds a published port to this composition's list of published input ports at the given index.

Definition at line 155 of file VuoComposition.cc.

◆ addPublishedOutputPort()

void VuoComposition::addPublishedOutputPort ( VuoPublishedPort port,
int  index 
)

Adds a published port to this composition's list of published output ports at the given index.

Definition at line 163 of file VuoComposition.cc.

◆ getCables()

set< VuoCable * > VuoComposition::getCables ( void  )

Returns the cables in this composition.

Definition at line 123 of file VuoComposition.cc.

◆ getComments()

set< VuoComment * > VuoComposition::getComments ( void  )

Returns the comments in this composition.

Definition at line 147 of file VuoComposition.cc.

◆ getDirectory()

string VuoComposition::getDirectory ( void  )

Returns the directory containing the composition's .vuo source file.

Definition at line 68 of file VuoComposition.cc.

◆ getIndexOfPublishedPort()

int VuoComposition::getIndexOfPublishedPort ( VuoPublishedPort port,
bool  isInput 
)

Returns the index of the published port in the list of published input or output ports.

Definition at line 234 of file VuoComposition.cc.

◆ getMetadata()

VuoCompositionMetadata * VuoComposition::getMetadata ( void  )

Returns the metadata associated with this composition.

Definition at line 52 of file VuoComposition.cc.

◆ getNodes()

set< VuoNode * > VuoComposition::getNodes ( void  )

Returns the nodes in this composition.

Definition at line 94 of file VuoComposition.cc.

◆ getProtocolAwarePublishedPortOrder()

vector< VuoPublishedPort * > VuoComposition::getProtocolAwarePublishedPortOrder ( VuoProtocol protocol,
bool  publishedInputs 
)

Returns an ordered list of the composition's published input or output ports, with published ports belonging to the provided protocol listed first, followed by published ports that are not part of the protocol.

Definition at line 249 of file VuoComposition.cc.

◆ getPublishedInputPorts()

vector< VuoPublishedPort * > VuoComposition::getPublishedInputPorts ( void  )

Returns the published input ports in this composition.

Definition at line 187 of file VuoComposition.cc.

◆ getPublishedInputPortWithName()

VuoPublishedPort * VuoComposition::getPublishedInputPortWithName ( string  name)

Returns the published input port with the given name, or null if none matches.

Definition at line 203 of file VuoComposition.cc.

◆ getPublishedOutputPorts()

vector< VuoPublishedPort * > VuoComposition::getPublishedOutputPorts ( void  )

Returns the published output ports in this composition.

Definition at line 195 of file VuoComposition.cc.

◆ getPublishedOutputPortWithName()

VuoPublishedPort * VuoComposition::getPublishedOutputPortWithName ( string  name)

Returns the published output port with the given name, or null if none matches.

Definition at line 211 of file VuoComposition.cc.

◆ removeCable()

void VuoComposition::removeCable ( VuoCable cable)

Disconnects and removes a cable from the composition.

Definition at line 112 of file VuoComposition.cc.

◆ removeComment()

void VuoComposition::removeComment ( VuoComment comment)

Removes a comment from the composition.

Definition at line 139 of file VuoComposition.cc.

◆ removeNode()

void VuoComposition::removeNode ( VuoNode node)

Removes a node from the composition.

The caller is responsible for removing any cables attached to the node.

Definition at line 86 of file VuoComposition.cc.

◆ removePublishedInputPort()

void VuoComposition::removePublishedInputPort ( int  index)

Removes the published port at the given index from this composition's list of published input ports.

Definition at line 171 of file VuoComposition.cc.

◆ removePublishedOutputPort()

void VuoComposition::removePublishedOutputPort ( int  index)

Removes the published port at the given index from this composition's list of published input ports.

Definition at line 179 of file VuoComposition.cc.

◆ setDirectory()

void VuoComposition::setDirectory ( string  directory)

Sets the directory containing the composition's .vuo source file.

Definition at line 60 of file VuoComposition.cc.

◆ setMetadata()

void VuoComposition::setMetadata ( VuoCompositionMetadata metadata,
bool  takeOwnership 
)

Assigns metadata to this composition.

If takeOwnership is true, this composition becomes responsible for destroying metadata. Otherwise, the caller is responsible.

Definition at line 40 of file VuoComposition.cc.


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