|
RTC Toolkit 6.1.0-pre1
|
A node representing a symbolic link in a tree. More...
Public Member Functions | |
| __init__ (self, DataPointPath path, DataPointPath links_to, TreeNode|None linked_node=None) | |
| get_value (self) | |
| Get the value from the linked node if the symlink is not dangling. | |
| set_value (self, Any new_value, *args, **kwargs) | |
| Set the value of the linked node if the symlink is not dangling. | |
| dict | get_metadata (self, bool except_internals=False) |
| Returns metadata of linked node with extra entry called symlink_target. | |
| set_metadata (self, dict new_metadata, *args, **kwargs) | |
| Set metadata on the linked node, excluding 'symlink_target'. | |
| update_metadata (self, str key, value, *args, **kwargs) | |
| Update metadata on the linked node. | |
| set_linked_node (self, TreeNode|None node, bool mark_cached=False) | |
| Set the node referenced by this symlink and optionally mark the link as cached. | |
| bool | is_leaf (self) |
| Symlink is always leaf. | |
| can_fetch_more (self) | |
| Return whether more data can be fetched from the linked node if the symlink is not dangling. | |
| bool | is_requested (self) |
| Return whether the linked node has a pending request if the symlink is not dangling. | |
| mark_ready (self) | |
| Sets symlink to a READY state. | |
| bool | is_dangling (self) |
| Return whether the symlink has no linked node. | |
| str | __str__ (self) |
Public Attributes | |
| links_to = links_to | |
| linked_node = None | |
| link_state = NodeDataState.READY | |
A node representing a symbolic link in a tree.
This node does not hold data. It contains only a linked TreeNode and uses the methods of the linked node to work with data and metadata. If the linked node does not exist, the symbolic link is dangling.
| gui.node.symlink_node.SymlinkNode.__init__ | ( | self, | |
| DataPointPath | path, | ||
| DataPointPath | links_to, | ||
| TreeNode | None | linked_node = None ) |
| str gui.node.symlink_node.SymlinkNode.__str__ | ( | self | ) |
| gui.node.symlink_node.SymlinkNode.can_fetch_more | ( | self | ) |
Return whether more data can be fetched from the linked node if the symlink is not dangling.
| dict gui.node.symlink_node.SymlinkNode.get_metadata | ( | self, | |
| bool | except_internals = False ) |
Returns metadata of linked node with extra entry called symlink_target.
If the symlink is danling, returns only dictionary with symlink_target.
| gui.node.symlink_node.SymlinkNode.get_value | ( | self | ) |
Get the value from the linked node if the symlink is not dangling.
| bool gui.node.symlink_node.SymlinkNode.is_dangling | ( | self | ) |
Return whether the symlink has no linked node.
| bool gui.node.symlink_node.SymlinkNode.is_leaf | ( | self | ) |
Symlink is always leaf.
| bool gui.node.symlink_node.SymlinkNode.is_requested | ( | self | ) |
Return whether the linked node has a pending request if the symlink is not dangling.
| gui.node.symlink_node.SymlinkNode.mark_ready | ( | self | ) |
Sets symlink to a READY state.
| gui.node.symlink_node.SymlinkNode.set_linked_node | ( | self, | |
| TreeNode | None | node, | ||
| bool | mark_cached = False ) |
Set the node referenced by this symlink and optionally mark the link as cached.
| gui.node.symlink_node.SymlinkNode.set_metadata | ( | self, | |
| dict | new_metadata, | ||
| * | args, | ||
| ** | kwargs ) |
Set metadata on the linked node, excluding 'symlink_target'.
Has no effect if the symlink is dangling.
| gui.node.symlink_node.SymlinkNode.set_value | ( | self, | |
| Any | new_value, | ||
| * | args, | ||
| ** | kwargs ) |
Set the value of the linked node if the symlink is not dangling.
| gui.node.symlink_node.SymlinkNode.update_metadata | ( | self, | |
| str | key, | ||
| value, | |||
| * | args, | ||
| ** | kwargs ) |
Update metadata on the linked node.
'symlink_target' is excluded. Has no effect if the symlink is dangling.
| gui.node.symlink_node.SymlinkNode.link_state = NodeDataState.READY |
| gui.node.symlink_node.SymlinkNode.linked_node = None |
| gui.node.symlink_node.SymlinkNode.links_to = links_to |