HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
UN_UniGraph Class Reference

#include <UN_UniGraph.h>

+ Inheritance diagram for UN_UniGraph:

Public Member Functions

UT_StringHolder name () const override
 Graph APIs: More...
 
bool isEmpty () const override
 Returns true if the graph has no nodes. More...
 
UNI_WireStyle wireStyle () const override
 The drawing style of the connection wires in the graph. More...
 
void setWireStyle (UNI_WireStyle wire_style) override
 The drawing style of the connection wires in the graph. More...
 
bool isValid (UNI_NodeID node_id) const override
 Returns true if the given ID refers to a valid item in this graph. More...
 
bool isValid (UNI_PortID port_id) const override
 Returns true if the given ID refers to a valid item in this graph. More...
 
bool isValid (UNI_WireID wire_id) const override
 Returns true if the given ID refers to a valid item in this graph. More...
 
bool isValid (UNI_StickyNoteID sticky_note_id) const override
 Returns true if the given ID refers to a valid item in this graph. More...
 
UNI_NodeID rootNode () const override
 Node APIs: More...
 
UT_StringHolder name (UNI_NodeID node_id) const override
 The name of a node. More...
 
UT_StringHolder path (UNI_NodeID node_id) const override
 The full path of the node. More...
 
UT_StringHolder categoryName (UNI_NodeID node_id) const override
 The category name of the node. More...
 
UT_StringHolder typeName (UNI_NodeID node_id) const override
 The type name of the node. More...
 
UT_StringHolder signatureName (UNI_NodeID node_id) const override
 The name of the current signature of the given node. More...
 
bool isMultiSignature (UNI_NodeID node_id) const override
 Returns true if the node has many signatures to choose from. More...
 
UT_Array< UNI_Signaturesignatures (UNI_NodeID node_id, bool compatible_only, bool force_include_current) const override
 
UT_StringHolder helpURL (UNI_NodeID node_id) const override
 
UNI_NodeID parentNode (UNI_NodeID node_id) const override
 
bool isSubnet (UNI_NodeID node_id) const override
 Returns true if the given node is a subnet (can have child nodes). More...
 
bool isEditable (UNI_NodeID node_id) const override
 
bool isEditableSubnet (UNI_NodeID parent_id) const override
 
UNI_NodeIDList childNodes (UNI_NodeID node_id) const override
 Returns the children nodes that live inside the given parent node. More...
 
UNI_NodeID findNode (UNI_NodeID from_id, const UT_StringRef &path) const override
 
bool isValidName (const UT_StringRef &name) const override
 Generic functions related to entity naming. More...
 
bool isNameInUse (UNI_NodeID parent_id, const UT_StringRef &name) const override
 Generic functions related to entity naming. More...
 
UT_StringHolder findUniqueName (UNI_NodeID parent_id, const UT_StringHolder &name) const override
 Generic functions related to entity naming. More...
 
UT_Vector2D position (UNI_NodeID node_id) const override
 The position of the node in the graph editor. More...
 
UT_Color color (UNI_NodeID node_id) const override
 The color tint of the node in the graph editor. More...
 
UT_StringHolder iconName (UNI_NodeID node_id) const override
 Returns the icon name for the given node. More...
 
UT_StringHolder comment (UNI_NodeID node_id) const override
 The user-authored comment for a node. More...
 
UT_StringArray tags (UNI_NodeID node_id) const override
 The list of tags associated with a node. More...
 
UT_StringHolder parmDialogScript (UNI_NodeID node_id) const override
 
UNI_ParmValue parmValue (UNI_NodeID node_id, const UT_StringRef &parm_name) const override
 Get the value of a parm on this node. More...
 
bool parmOverriddenByConnection (UNI_NodeID node_id, const UT_StringRef &parm_name) const override
 
int numberOfInputPorts (UNI_NodeID node_id) const override
 Input ports of a node. More...
 
UNI_PortIDList inputPorts (UNI_NodeID node_id) const override
 Input ports of a node. More...
 
UNI_PortID inputPort (UNI_NodeID node_id, int port_index) const override
 Input ports of a node. More...
 
int findInputPortIndex (UNI_NodeID node_id, UNI_PortID port_id) const override
 Input ports of a node. More...
 
int numberOfOutputPorts (UNI_NodeID node_id) const override
 Output ports of a node. More...
 
UNI_PortIDList outputPorts (UNI_NodeID node_id) const override
 Output ports of a node. More...
 
UNI_PortID outputPort (UNI_NodeID node_id, int port_index) const override
 Output ports of a node. More...
 
int findOutputPortIndex (UNI_NodeID node_id, UNI_PortID port_id) const override
 Output ports of a node. More...
 
bool hasDynamicPorts (UNI_NodeID node_id) const override
 
bool wireDirectlyToContainer () const override
 
UT_Vector2D containerConnectPosition (UNI_NodeID parent_id, UNI_ContainerConnectType contype) const override
 
UT_Color containerConnectColor (UNI_NodeID parent_id, UNI_ContainerConnectType contype) const override
 
UNI_NodeID ownerNode (UNI_PortID port_id) const override
 Port APIs: More...
 
UNI_PortKind portKind (UNI_PortID port_id) const override
 Returns what kind of a port this is: input or output. More...
 
bool portAcceptsSubPorts (UNI_PortID port_id) const override
 Returns whether the port accepts subports. More...
 
bool portIsSubPort (UNI_PortID port_id) const override
 Returns whether the port is a subport. More...
 
UNI_PortID outerPort (UNI_PortID port_id) const override
 Returns the "outer port" of a subport. More...
 
UNI_PortIDList subnetOutputPorts (UNI_PortID port_id) const override
 
UNI_PortIDList subnetInputPorts (UNI_PortID port_id) const override
 
UT_StringHolder name (UNI_PortID port_id) const override
 The name of the port. Some ports can be renamed. More...
 
bool canSetName (UNI_PortID port_id) const override
 Some graphs support setting port names. More...
 
UT_StringHolder label (UNI_PortID port_id) const override
 The label of the port. Some ports can be renamed. More...
 
UT_StringHolder typeName (UNI_PortID port_id) const override
 Returns the data type name for the given port. More...
 
UT_StringHolder colorName (UNI_PortID port_id) const override
 
UNI_PortShape shape (UNI_PortID port_id) const override
 Returns the visual shape of the port in the UI. More...
 
UNI_WireIDList childWires (UNI_NodeID node_id) const override
 Wire APIs: More...
 
UNI_PortID srcPort (UNI_WireID wire_id) const override
 
UNI_PortID dstPort (UNI_WireID wire_id) const override
 
UNI_WireIDList srcWires (UNI_PortID port_id) const override
 Return the wires that connect to a given port. More...
 
UNI_WireIDList dstWires (UNI_PortID port_id) const override
 Return the wires that connect to a given port. More...
 
UNI_StickyNoteIDList childStickyNotes (UNI_NodeID parent_id) const override
 Sticky note APIs: More...
 
UNI_StickyNoteID findStickyNote (UNI_NodeID from_id, const UT_StringRef &path) const override
 Find the sticky note at a path relative to a starting node. More...
 
UT_StringHolder name (UNI_StickyNoteID note_id) const override
 The name of a sticky note. More...
 
UT_StringHolder path (UNI_StickyNoteID note_id) const override
 The full path of the sticky note. More...
 
UNI_NodeID ownerNode (UNI_StickyNoteID note_id) const override
 Returns the id of the node that contains this sticky note. More...
 
UT_StringHolder text (UNI_StickyNoteID note_id) const override
 Returns the sticky note's contents. More...
 
UT_Color textColor (UNI_StickyNoteID note_id) const override
 Returns the sticky note's text (foreground) color. More...
 
float textSize (UNI_StickyNoteID note_id) const override
 Returns the sticky note's text size. More...
 
UT_Color color (UNI_StickyNoteID note_id) const override
 Returns the sticky note's (background) color. More...
 
UT_Vector2D position (UNI_StickyNoteID note_id) const override
 Returns the sticky note's position in the graph editor. More...
 
UT_Vector2D size (UNI_StickyNoteID note_id) const override
 Returns the sticky note's size (width & height). More...
 
bool isCollapsed (UNI_StickyNoteID note_id) const override
 Returns true if the sticky note is collapsed (minimized). More...
 
bool isBackgroundHidden (UNI_StickyNoteID note_id) const override
 
bool copyItems (UNI_NodeID parent_id, const UNI_NodeIDList &node_ids, const UNI_StickyNoteIDList &note_ids, std::ostream &os) const override
 
- Public Member Functions inherited from UNI_Graph
virtual ~UNI_Graph ()
 Destructor. More...
 
UNI_GraphID graphID () const
 
bool isEditable () const
 Control whether this graph is editable. More...
 
void setEditable (bool editable)
 Control whether this graph is editable. More...
 
UNI_NodeID currentChildNode (UNI_NodeID parent_id)
 Functions for tracking the current and selected nodes and wires. More...
 
const UT_Array
< UNI_SelectableItemID > & 
selectedItems () const
 Functions for tracking the current and selected nodes and wires. More...
 
template<typename T >
UT_Array< TselectedItemsOfType () const
 Functions for tracking the current and selected nodes and wires. More...
 
bool isItemSelected (UNI_SelectableItemID id)
 Functions for tracking the current and selected nodes and wires. More...
 
void addSelectedItem (UNI_SelectableItemID id)
 Functions for tracking the current and selected nodes and wires. More...
 
void removeSelectedItem (UNI_SelectableItemID id)
 Functions for tracking the current and selected nodes and wires. More...
 
void clearSelection ()
 Functions for tracking the current and selected nodes and wires. More...
 
ChangeCallbackID addChangeCallback (const UNI_Graph::ChangeCallback &cb)
 
void removeChangeCallback (ChangeCallbackID id)
 
- Public Member Functions inherited from UT_IntrusiveRefCounter< UNI_Graph, UNI_GraphDeleter >
SYS_FORCE_INLINE UT_IntrusiveRefCounter () noexcept
 Default constructor: Sets counter to 0. More...
 
SYS_FORCE_INLINE UT_IntrusiveRefCounter (const UT_IntrusiveRefCounter &) noexcept
 Copy constructor: Sets counter to 0. More...
 
UT_IntrusiveRefCounteroperator= (const UT_IntrusiveRefCounter &) noexcept
 Assignment operator: Does not modify counter. More...
 
SYS_FORCE_INLINE uint32 use_count () const noexcept
 Return current counter. More...
 
SYS_FORCE_INLINE bool conditionalAddRef () noexcept
 

Protected Member Functions

 UN_UniGraph ()
 Constructor. More...
 
void setGraphData (UN_GraphData *graph_data)
 
const UNI_ManageruniManager () const
 Returns the UNI manager this graph belongs to. More...
 
UNI_NodeID createNode (UNI_NodeID parent_id, const UT_StringHolder &node_name, const UT_StringHolder &node_type_name, const UT_StringHolder &signature_name=UT_StringHolder()) override
 Non-const methods are all protected. More...
 
UNI_NodeID createSubnet (UNI_NodeID parent_id, const UT_StringHolder &subnet_node_name, const UNI_PortIDList &create_input_ports, const UNI_PortIDList &create_output_ports) override
 Non-const methods are all protected. More...
 
void setName (UNI_NodeID node_id, const UT_StringHolder &name) override
 Non-const methods are all protected. More...
 
void setSignature (UNI_NodeID node_id, const UT_StringHolder &signature_name) override
 Non-const methods are all protected. More...
 
void updateDownstreamPortTypes (UNI_NodeID node_id, bool update_node) override
 Non-const methods are all protected. More...
 
void updateDownstreamPortTypes (UNI_PortID port_id, bool update_port) override
 Non-const methods are all protected. More...
 
void setPosition (UNI_NodeID node_id, const UT_Vector2D &pos) override
 Non-const methods are all protected. More...
 
void setColor (UNI_NodeID node_id, const UT_Color &clr) override
 Non-const methods are all protected. More...
 
void setComment (UNI_NodeID node_id, const UT_StringHolder &comment) override
 Non-const methods are all protected. More...
 
void setTags (UNI_NodeID node_id, const UT_StringArray &tags) override
 Non-const methods are all protected. More...
 
void setParmValue (UNI_NodeID node_id, const UT_StringRef &parm_name, const UNI_ParmValue &value) override
 Non-const methods are all protected. More...
 
void destroy (UNI_NodeID node_id) override
 Non-const methods are all protected. More...
 
void setContainerConnectPosition (UNI_NodeID parent_id, UNI_ContainerConnectType contype, const UT_Vector2D &pos) override
 Non-const methods are all protected. More...
 
void setContainerConnectColor (UNI_NodeID parent_id, UNI_ContainerConnectType contype, const UT_Color &clr) override
 Non-const methods are all protected. More...
 
void setName (UNI_PortID port_id, const UT_StringHolder &name) override
 Non-const methods are all protected. More...
 
UNI_WireID createWire (UNI_PortID src, UNI_PortID dst) override
 Non-const methods are all protected. More...
 
void destroy (UNI_WireID wire_id) override
 Non-const methods are all protected. More...
 
UNI_StickyNoteID createStickyNote (UNI_NodeID parent_id, const UT_StringHolder &name) override
 Non-const methods are all protected. More...
 
void setName (UNI_StickyNoteID note_id, const UT_StringHolder &name) override
 Non-const methods are all protected. More...
 
void setPosition (UNI_StickyNoteID note_id, const UT_Vector2D &pos) override
 Non-const methods are all protected. More...
 
void setSize (UNI_StickyNoteID note_id, const UT_Vector2D &size) override
 Non-const methods are all protected. More...
 
void setColor (UNI_StickyNoteID note_id, const UT_Color &clr) override
 Non-const methods are all protected. More...
 
void setText (UNI_StickyNoteID note_id, const UT_StringHolder &text) override
 Non-const methods are all protected. More...
 
void setTextColor (UNI_StickyNoteID note_id, const UT_Color &clr) override
 Non-const methods are all protected. More...
 
void setTextSize (UNI_StickyNoteID note_id, const float size) override
 Non-const methods are all protected. More...
 
void setCollapsed (UNI_StickyNoteID note_id, bool collapsed) override
 Non-const methods are all protected. More...
 
void setBackgroundHidden (UNI_StickyNoteID note_id, bool hidden) override
 Non-const methods are all protected. More...
 
void destroy (UNI_StickyNoteID note_id) override
 Non-const methods are all protected. More...
 
bool pasteItems (UNI_NodeID parent_id, UNI_NodeIDList &node_ids, UNI_StickyNoteIDList &note_ids, std::istream &is, UT_StringMap< UT_StringHolder > *rename_map) override
 Non-const methods are all protected. More...
 
const UNI_CategoryuniCategory (const UT_StringRef &category_name) const
 Returns the UNI manager this graph belongs to. More...
 
const UN_UniCategoryunCategory (const UT_StringRef &category_name) const
 Returns the UNI manager this graph belongs to. More...
 
const UN_GraphDataunGraphData () const
 Returns the underlying UN graph. More...
 
UN_GraphDataunGraphData ()
 Returns the underlying UN graph. More...
 
UN_Node unNode (UNI_NodeID id)
 Convenience methods to get a UN items from an UNI ID. More...
 
UN_ConstNode unNode (UNI_NodeID id) const
 Convenience methods to get a UN items from an UNI ID. More...
 
UN_Port unPort (UNI_PortID id)
 Convenience methods to get a UN items from an UNI ID. More...
 
UN_ConstPort unPort (UNI_PortID id) const
 Convenience methods to get a UN items from an UNI ID. More...
 
const UN_PortTypeunPortType (UNI_PortID id) const
 Convenience methods to get a UN items from an UNI ID. More...
 
UN_StickyNote unStickyNote (UNI_StickyNoteID id)
 Convenience methods to get a UN items from an UNI ID. More...
 
UN_ConstStickyNote unStickyNote (UNI_StickyNoteID id) const
 Convenience methods to get a UN items from an UNI ID. More...
 
- Protected Member Functions inherited from UNI_Graph
 UNI_Graph ()
 
void forceTriggerChangeCallbacks (const UNI_GraphChangeType &add_change_type=UNI_GraphChangeType())
 
- Protected Member Functions inherited from UT_IntrusiveRefCounter< UNI_Graph, UNI_GraphDeleter >
SYS_FORCE_INLINE ~UT_IntrusiveRefCounter ()
 Destructor: Only derived classes can destruct this. More...
 

Additional Inherited Members

- Public Types inherited from UNI_Graph
using ChangeCallback = UT_Function< void(UNI_Graph &, UNI_GraphChangeType, bool)>
 
using ChangeCallbackID = int
 
- Static Public Member Functions inherited from UNI_Graph
static UNI_GraphfindGraph (UNI_GraphID id)
 Returns a UNI graph given its ID. Returns a null if not found. More...
 

Detailed Description

Definition at line 28 of file UN_UniGraph.h.

Constructor & Destructor Documentation

UN_UniGraph::UN_UniGraph ( )
protected

Constructor.

Member Function Documentation

bool UN_UniGraph::canSetName ( UNI_PortID  port_id) const
overridevirtual

Some graphs support setting port names.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::categoryName ( UNI_NodeID  node_id) const
overridevirtual

The category name of the node.

Implements UNI_Graph.

UNI_NodeIDList UN_UniGraph::childNodes ( UNI_NodeID  parent_id) const
overridevirtual

Returns the children nodes that live inside the given parent node.

Implements UNI_Graph.

UNI_StickyNoteIDList UN_UniGraph::childStickyNotes ( UNI_NodeID  parent_id) const
overridevirtual

Sticky note APIs:

Implements UNI_Graph.

UNI_WireIDList UN_UniGraph::childWires ( UNI_NodeID  node_id) const
overridevirtual

Wire APIs:

Implements UNI_Graph.

UT_Color UN_UniGraph::color ( UNI_NodeID  node_id) const
overridevirtual

The color tint of the node in the graph editor.

Implements UNI_Graph.

UT_Color UN_UniGraph::color ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns the sticky note's (background) color.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::colorName ( UNI_PortID  port_id) const
overridevirtual

Returns the UI color name for the given port. The color name should adhere to the UIgetMiscColor() conventions. This method allows for color scheme adjustment of the actual color.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::comment ( UNI_NodeID  node_id) const
overridevirtual

The user-authored comment for a node.

Implements UNI_Graph.

UT_Color UN_UniGraph::containerConnectColor ( UNI_NodeID  parent_id,
UNI_ContainerConnectType  contype 
) const
overridevirtual

Some graphs allow wiring directly from a container node to nodes inside the container. In this case, wireDirectlyToContainer will return true. The other methods here are for controlling the appearance of the UI for making connections to the container node when inside that container.

Implements UNI_Graph.

UT_Vector2D UN_UniGraph::containerConnectPosition ( UNI_NodeID  parent_id,
UNI_ContainerConnectType  contype 
) const
overridevirtual

Some graphs allow wiring directly from a container node to nodes inside the container. In this case, wireDirectlyToContainer will return true. The other methods here are for controlling the appearance of the UI for making connections to the container node when inside that container.

Implements UNI_Graph.

bool UN_UniGraph::copyItems ( UNI_NodeID  parent_id,
const UNI_NodeIDList &  node_ids,
const UNI_StickyNoteIDList &  note_ids,
std::ostream &  os 
) const
overridevirtual

Fill the supplied output stream with data that can be used to make copies of the specified items.

Implements UNI_Graph.

UNI_NodeID UN_UniGraph::createNode ( UNI_NodeID  parent_id,
const UT_StringHolder node_name,
const UT_StringHolder node_type_name,
const UT_StringHolder signature_name = UT_StringHolder() 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

UNI_StickyNoteID UN_UniGraph::createStickyNote ( UNI_NodeID  parent_id,
const UT_StringHolder name 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

UNI_NodeID UN_UniGraph::createSubnet ( UNI_NodeID  parent_id,
const UT_StringHolder subnet_node_name,
const UNI_PortIDList &  create_input_ports,
const UNI_PortIDList &  create_output_ports 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

UNI_WireID UN_UniGraph::createWire ( UNI_PortID  src,
UNI_PortID  dst 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::destroy ( UNI_NodeID  node_id)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::destroy ( UNI_WireID  wire_id)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::destroy ( UNI_StickyNoteID  note_id)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

UNI_PortID UN_UniGraph::dstPort ( UNI_WireID  wire_id) const
overridevirtual

Get the start (src) and end (dst) ports for a wire. Note that either an input or output port may be the start or end point of a wire. The permissibility and meaning of this will depend on the specific graph implementation.

Implements UNI_Graph.

UNI_WireIDList UN_UniGraph::dstWires ( UNI_PortID  port_id) const
overridevirtual

Return the wires that connect to a given port.

Implements UNI_Graph.

int UN_UniGraph::findInputPortIndex ( UNI_NodeID  node_id,
UNI_PortID  port_id 
) const
overridevirtual

Input ports of a node.

Implements UNI_Graph.

UNI_NodeID UN_UniGraph::findNode ( UNI_NodeID  from_id,
const UT_StringRef path 
) const
overridevirtual

Finds the node at the specified path relative to the given node. If the path is an absolute path, the from_id isn't used.

Implements UNI_Graph.

int UN_UniGraph::findOutputPortIndex ( UNI_NodeID  node_id,
UNI_PortID  port_id 
) const
overridevirtual

Output ports of a node.

Implements UNI_Graph.

UNI_StickyNoteID UN_UniGraph::findStickyNote ( UNI_NodeID  from_id,
const UT_StringRef path 
) const
overridevirtual

Find the sticky note at a path relative to a starting node.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::findUniqueName ( UNI_NodeID  parent_id,
const UT_StringHolder name 
) const
overridevirtual

Generic functions related to entity naming.

Implements UNI_Graph.

bool UN_UniGraph::hasDynamicPorts ( UNI_NodeID  node_id) const
overridevirtual

Return true if a node has a variable number of inputs or outputs. This does not include "subports" in APEX, which are not individually named and are not "real" ports.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::helpURL ( UNI_NodeID  node_id) const
overridevirtual

The help URL for the node. Used for UT_HelpManager::openURL() which accepts protocols such as "http://u.r.l", "hdox://u.r.l", "operator:category/name", etc.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::iconName ( UNI_NodeID  node_id) const
overridevirtual

Returns the icon name for the given node.

Implements UNI_Graph.

UNI_PortID UN_UniGraph::inputPort ( UNI_NodeID  node_id,
int  port_index 
) const
overridevirtual

Input ports of a node.

Implements UNI_Graph.

UNI_PortIDList UN_UniGraph::inputPorts ( UNI_NodeID  node_id) const
overridevirtual

Input ports of a node.

Implements UNI_Graph.

bool UN_UniGraph::isBackgroundHidden ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns true if the background of the sticky note is not drawn, effectively making it transparent.

Implements UNI_Graph.

bool UN_UniGraph::isCollapsed ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns true if the sticky note is collapsed (minimized).

Implements UNI_Graph.

bool UN_UniGraph::isEditable ( UNI_NodeID  node_id) const
overridevirtual

Returns true if the given node can be modified (ie, is inside an editable subnet). Ie, it can be connected to a new source, and its parameters can be set.

Implements UNI_Graph.

bool UN_UniGraph::isEditableSubnet ( UNI_NodeID  parent_id) const
overridevirtual

Returns true if the subnet inside the given parent node can be modified. Eg, new connections can be made between children, their parameters can be set, etc.

Implements UNI_Graph.

bool UN_UniGraph::isEmpty ( ) const
overridevirtual

Returns true if the graph has no nodes.

Implements UNI_Graph.

bool UN_UniGraph::isMultiSignature ( UNI_NodeID  node_id) const
overridevirtual

Returns true if the node has many signatures to choose from.

Implements UNI_Graph.

bool UN_UniGraph::isNameInUse ( UNI_NodeID  parent_id,
const UT_StringRef name 
) const
overridevirtual

Generic functions related to entity naming.

Implements UNI_Graph.

bool UN_UniGraph::isSubnet ( UNI_NodeID  node_id) const
overridevirtual

Returns true if the given node is a subnet (can have child nodes).

Implements UNI_Graph.

bool UN_UniGraph::isValid ( UNI_NodeID  node_id) const
overridevirtual

Returns true if the given ID refers to a valid item in this graph.

Implements UNI_Graph.

bool UN_UniGraph::isValid ( UNI_PortID  port_id) const
overridevirtual

Returns true if the given ID refers to a valid item in this graph.

Implements UNI_Graph.

bool UN_UniGraph::isValid ( UNI_WireID  wire_id) const
overridevirtual

Returns true if the given ID refers to a valid item in this graph.

Implements UNI_Graph.

bool UN_UniGraph::isValid ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns true if the given ID refers to a valid item in this graph.

Implements UNI_Graph.

bool UN_UniGraph::isValidName ( const UT_StringRef name) const
overridevirtual

Generic functions related to entity naming.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::label ( UNI_PortID  port_id) const
overridevirtual

The label of the port. Some ports can be renamed.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::name ( ) const
overridevirtual

Graph APIs:

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::name ( UNI_NodeID  node_id) const
overridevirtual

The name of a node.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::name ( UNI_PortID  port_id) const
overridevirtual

The name of the port. Some ports can be renamed.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::name ( UNI_StickyNoteID  note_id) const
overridevirtual

The name of a sticky note.

Implements UNI_Graph.

int UN_UniGraph::numberOfInputPorts ( UNI_NodeID  node_id) const
overridevirtual

Input ports of a node.

Implements UNI_Graph.

int UN_UniGraph::numberOfOutputPorts ( UNI_NodeID  node_id) const
overridevirtual

Output ports of a node.

Implements UNI_Graph.

UNI_PortID UN_UniGraph::outerPort ( UNI_PortID  port_id) const
overridevirtual

Returns the "outer port" of a subport.

Implements UNI_Graph.

UNI_PortID UN_UniGraph::outputPort ( UNI_NodeID  node_id,
int  port_index 
) const
overridevirtual

Output ports of a node.

Implements UNI_Graph.

UNI_PortIDList UN_UniGraph::outputPorts ( UNI_NodeID  node_id) const
overridevirtual

Output ports of a node.

Implements UNI_Graph.

UNI_NodeID UN_UniGraph::ownerNode ( UNI_PortID  port_id) const
overridevirtual

Port APIs:

Implements UNI_Graph.

UNI_NodeID UN_UniGraph::ownerNode ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns the id of the node that contains this sticky note.

Implements UNI_Graph.

UNI_NodeID UN_UniGraph::parentNode ( UNI_NodeID  node_id) const
overridevirtual

APIs for getting information about a node. Returns the parent of the given node. Ie, nodes can be nested, so this returns the node inside which the given child node lives.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::parmDialogScript ( UNI_NodeID  node_id) const
overridevirtual

The parameter descriptions for the specified node. This is used to build a parm dialog.

Implements UNI_Graph.

bool UN_UniGraph::parmOverriddenByConnection ( UNI_NodeID  node_id,
const UT_StringRef parm_name 
) const
overridevirtual

Return true if there is a port corresponding to this parm, and that port is connected, resulting in this parm having no effect.

Implements UNI_Graph.

UNI_ParmValue UN_UniGraph::parmValue ( UNI_NodeID  node_id,
const UT_StringRef parm_name 
) const
overridevirtual

Get the value of a parm on this node.

Implements UNI_Graph.

bool UN_UniGraph::pasteItems ( UNI_NodeID  parent_id,
UNI_NodeIDList &  node_ids,
UNI_StickyNoteIDList &  note_ids,
std::istream &  is,
UT_StringMap< UT_StringHolder > *  rename_map 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::path ( UNI_NodeID  node_id) const
overridevirtual

The full path of the node.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::path ( UNI_StickyNoteID  note_id) const
overridevirtual

The full path of the sticky note.

Implements UNI_Graph.

bool UN_UniGraph::portAcceptsSubPorts ( UNI_PortID  port_id) const
overridevirtual

Returns whether the port accepts subports.

Implements UNI_Graph.

bool UN_UniGraph::portIsSubPort ( UNI_PortID  port_id) const
overridevirtual

Returns whether the port is a subport.

Implements UNI_Graph.

UNI_PortKind UN_UniGraph::portKind ( UNI_PortID  port_id) const
overridevirtual

Returns what kind of a port this is: input or output.

Implements UNI_Graph.

UT_Vector2D UN_UniGraph::position ( UNI_NodeID  node_id) const
overridevirtual

The position of the node in the graph editor.

Implements UNI_Graph.

UT_Vector2D UN_UniGraph::position ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns the sticky note's position in the graph editor.

Implements UNI_Graph.

UNI_NodeID UN_UniGraph::rootNode ( ) const
overridevirtual

Node APIs:

Implements UNI_Graph.

void UN_UniGraph::setBackgroundHidden ( UNI_StickyNoteID  note_id,
bool  hidden 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setCollapsed ( UNI_StickyNoteID  note_id,
bool  collapsed 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setColor ( UNI_NodeID  node_id,
const UT_Color clr 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setColor ( UNI_StickyNoteID  note_id,
const UT_Color clr 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setComment ( UNI_NodeID  node_id,
const UT_StringHolder comment 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setContainerConnectColor ( UNI_NodeID  parent_id,
UNI_ContainerConnectType  contype,
const UT_Color clr 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setContainerConnectPosition ( UNI_NodeID  parent_id,
UNI_ContainerConnectType  contype,
const UT_Vector2D pos 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setGraphData ( UN_GraphData graph_data)
inlineprotected

Sets the graph data. Must be called in the sub-class constructor, or at least before calling any of the methods.

Definition at line 37 of file UN_UniGraph.h.

void UN_UniGraph::setName ( UNI_NodeID  node_id,
const UT_StringHolder name 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setName ( UNI_PortID  port_id,
const UT_StringHolder name 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setName ( UNI_StickyNoteID  note_id,
const UT_StringHolder name 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setParmValue ( UNI_NodeID  node_id,
const UT_StringRef parm_name,
const UNI_ParmValue value 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setPosition ( UNI_NodeID  node_id,
const UT_Vector2D pos 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setPosition ( UNI_StickyNoteID  note_id,
const UT_Vector2D pos 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setSignature ( UNI_NodeID  node_id,
const UT_StringHolder signature_name 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setSize ( UNI_StickyNoteID  note_id,
const UT_Vector2D size 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setTags ( UNI_NodeID  node_id,
const UT_StringArray tags 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setText ( UNI_StickyNoteID  note_id,
const UT_StringHolder text 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setTextColor ( UNI_StickyNoteID  note_id,
const UT_Color clr 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setTextSize ( UNI_StickyNoteID  note_id,
const float  size 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::setWireStyle ( UNI_WireStyle  wire_style)
overridevirtual

The drawing style of the connection wires in the graph.

Implements UNI_Graph.

UNI_PortShape UN_UniGraph::shape ( UNI_PortID  port_id) const
overridevirtual

Returns the visual shape of the port in the UI.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::signatureName ( UNI_NodeID  node_id) const
overridevirtual

The name of the current signature of the given node.

Implements UNI_Graph.

UT_Array<UNI_Signature> UN_UniGraph::signatures ( UNI_NodeID  node_id,
bool  compatible_only,
bool  force_include_current 
) const
overridevirtual

The list of function signature names this node (or node's type) offers. If compatible_only is true, the list contains signatures whose input/output types are compatible with current wire connections on the node; otherwise, resturns all available signatures. If force_include_current is true, the list will include the current node signature name eve if it may not be part of official list.

Implements UNI_Graph.

UT_Vector2D UN_UniGraph::size ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns the sticky note's size (width & height).

Implements UNI_Graph.

UNI_PortID UN_UniGraph::srcPort ( UNI_WireID  wire_id) const
overridevirtual

Get the start (src) and end (dst) ports for a wire. Note that either an input or output port may be the start or end point of a wire. The permissibility and meaning of this will depend on the specific graph implementation.

Implements UNI_Graph.

UNI_WireIDList UN_UniGraph::srcWires ( UNI_PortID  port_id) const
overridevirtual

Return the wires that connect to a given port.

Implements UNI_Graph.

UNI_PortIDList UN_UniGraph::subnetInputPorts ( UNI_PortID  port_id) const
overridevirtual

Returns the port to which wires must connect in order to act as a dst wire from a subnet's input port. Returns an empty list if the provided port isn't an input port of a subnet node.

Implements UNI_Graph.

UNI_PortIDList UN_UniGraph::subnetOutputPorts ( UNI_PortID  port_id) const
overridevirtual

Returns the port to which wires must connect in order to serve as the src wire for a subnet's output port. Returns an empty list if the provided port isn't an output port of a subnet node.

Implements UNI_Graph.

UT_StringArray UN_UniGraph::tags ( UNI_NodeID  node_id) const
overridevirtual

The list of tags associated with a node.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::text ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns the sticky note's contents.

Implements UNI_Graph.

UT_Color UN_UniGraph::textColor ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns the sticky note's text (foreground) color.

Implements UNI_Graph.

float UN_UniGraph::textSize ( UNI_StickyNoteID  note_id) const
overridevirtual

Returns the sticky note's text size.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::typeName ( UNI_NodeID  node_id) const
overridevirtual

The type name of the node.

Implements UNI_Graph.

UT_StringHolder UN_UniGraph::typeName ( UNI_PortID  port_id) const
overridevirtual

Returns the data type name for the given port.

Implements UNI_Graph.

const UN_UniCategory* UN_UniGraph::unCategory ( const UT_StringRef category_name) const
protected

Returns the UNI manager this graph belongs to.

const UN_GraphData& UN_UniGraph::unGraphData ( ) const
inlineprotected

Returns the underlying UN graph.

Definition at line 235 of file UN_UniGraph.h.

UN_GraphData& UN_UniGraph::unGraphData ( )
inlineprotected

Returns the underlying UN graph.

Definition at line 240 of file UN_UniGraph.h.

const UNI_Category* UN_UniGraph::uniCategory ( const UT_StringRef category_name) const
protected

Returns the UNI manager this graph belongs to.

const UNI_Manager* UN_UniGraph::uniManager ( ) const
protected

Returns the UNI manager this graph belongs to.

UN_Node UN_UniGraph::unNode ( UNI_NodeID  id)
inlineprotected

Convenience methods to get a UN items from an UNI ID.

Definition at line 248 of file UN_UniGraph.h.

UN_ConstNode UN_UniGraph::unNode ( UNI_NodeID  id) const
inlineprotected

Convenience methods to get a UN items from an UNI ID.

Definition at line 250 of file UN_UniGraph.h.

UN_Port UN_UniGraph::unPort ( UNI_PortID  id)
inlineprotected

Convenience methods to get a UN items from an UNI ID.

Definition at line 252 of file UN_UniGraph.h.

UN_ConstPort UN_UniGraph::unPort ( UNI_PortID  id) const
inlineprotected

Convenience methods to get a UN items from an UNI ID.

Definition at line 254 of file UN_UniGraph.h.

const UN_PortType* UN_UniGraph::unPortType ( UNI_PortID  id) const
protected

Convenience methods to get a UN items from an UNI ID.

UN_StickyNote UN_UniGraph::unStickyNote ( UNI_StickyNoteID  id)
inlineprotected

Convenience methods to get a UN items from an UNI ID.

Definition at line 257 of file UN_UniGraph.h.

UN_ConstStickyNote UN_UniGraph::unStickyNote ( UNI_StickyNoteID  id) const
inlineprotected

Convenience methods to get a UN items from an UNI ID.

Definition at line 259 of file UN_UniGraph.h.

void UN_UniGraph::updateDownstreamPortTypes ( UNI_NodeID  node_id,
bool  update_node 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

void UN_UniGraph::updateDownstreamPortTypes ( UNI_PortID  port_id,
bool  update_port 
)
overrideprotectedvirtual

Non-const methods are all protected.

Implements UNI_Graph.

bool UN_UniGraph::wireDirectlyToContainer ( ) const
overridevirtual

Some graphs allow wiring directly from a container node to nodes inside the container. In this case, wireDirectlyToContainer will return true. The other methods here are for controlling the appearance of the UI for making connections to the container node when inside that container.

Implements UNI_Graph.

UNI_WireStyle UN_UniGraph::wireStyle ( ) const
overridevirtual

The drawing style of the connection wires in the graph.

Implements UNI_Graph.


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