Filtered All Shortest Paths
Parameters
Parameter |
Mandatory |
Description |
Type |
Value Range |
Default Value |
---|---|---|---|---|---|
source |
Yes |
Source vertex ID |
String |
- - |
- |
target |
Yes |
Target vertex ID |
String |
- |
- |
directed |
No |
Whether an edge is directed |
Boolean |
The value can be true or false. |
false |
Parameter |
Type |
Description |
---|---|---|
paths |
List |
Paths between the source and target vertices. The format is as follows: [[path1],[path2]] where For the format of each path, see Shortest Path. |
paths_number |
Integer |
Number of paths |
source |
String |
Source vertex ID |
target |
String |
Target vertex ID |
Example Request
POST /ges/v1.0/{project_id}/graphs/{graph_name}/action?action_id=execute-algorithm { "algorithmName": "filtered_all_shortest_paths", "edge_filter": { "property_filter": { "leftvalue": { "label_name": "labelName" }, "predicate": "=", "rightvalue": { "value": "friends" } } }, "parameters": { "source": "Alice", "target": "Jay", "directed": true } }
Response
{ "data": { "outputs": { "data_return_size": 8, "paths": [ [ "Alice", "Janet", "Yvette", "Willy", "Jay" ], ... [ "Alice", "Jacob", "Jimmy", "Cary", "Jay" ] ], "runtime": 0.005276, "source": "Alice", "data_offset": 0, "paths_number": 8, "data_total_size": 8, "target": "Jay" } } }
Parameter |
Type |
Description |
---|---|---|
paths |
List |
Paths between the source and target vertices. The format is as follows: [[path1],[path2]] where For the format of each path, see Shortest Path. |
paths_number |
Integer |
Number of paths |
source |
String |
Source vertex ID |
target |
String |
Target vertex ID |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.