Add wrapper around node and connection #9
Labels
No labels
Complexity/Higest
Complexity/High
Complexity/Low
Complexity/Lowest
Complexity/Normal
Importance/High
Importance/Highest
Importance/Low
Importance/Lowest
Importance/Normal
Kind/Bug
Kind/Documentation
Kind/Feature
Kind/Structure
OS/Linux
OS/MacOS
OS/Windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
Blocks
#2 Add examples use
linarphy/galaxy-graph
Reference
linarphy/galaxy-graph#9
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The goal is to avoid user of this library to use pattern like
This already exists with
Node.connectwhich is a wrapper aroundNode.state.online.connectand raise an error if the node is not online.These pattern happens right now when we want:
There is two solutions I think of:
Node.get_neighbors_by_node_type(type_),Node.get_neighbors_by_node_data(filter_), etc…utils.get_neighbors_by_node_type(node, type_), etc…I prefer option 1 over option 2. Ultimately, I feel like option 3 is the future proof best answer. We shouldn’t need to have that many function to fetch for neighbors. Having a query engine that can express exactly what we want is better.
This can be interesting: https://github.com/cdhx/SPARQL_parse, but not well packaged and quite old. Can be a starting point.
Option 1 done, will work on option 3 later.