Misc Operations
These Operations don't fit under other pages and are not core operations.
This directed graph is used in all the examples on this page:
graph TD
1(1, count=3) -- count=3 --> 2
1 -- count=1 --> 4
2(2, count=1) -- count=2 --> 3
2 -- count=1 --> 4(4, count=1)
2 -- count=1 --> 5(5, count=3)
3(3, count=2) -- count=4 --> 4
GetFromEndpoint
Gets data from an endpoint. Javadoc
Example
ScoreOperationChain
Determines a "score" for an OperationChain. This is used to determine whether a particular user has the required permissions to execute a given OperationChain. Javadoc
This operation requires Store configuration to be set before it can be used. See the Operation Score Guide for how to do this.
Example ScoreOperationChain
Results:
Example of ScoreOperationChain with custom named score
Here we have added a NamedOperation to the NamedOperationCache, with a custom score of 3. In our ScoreOperationChainDeclaration.json file, we have also declared that this should be resolved with a NamedOperationScoreResolver. With Limit declared as having a score of 2, the above chain correctly has a score of 5.
{
"class" : "ScoreOperationChain",
"operationChain" : {
"class" : "OperationChain",
"operations" : [ {
"class" : "NamedOperation",
"input" : [ {
"class" : "EntitySeed",
"class" : "EntitySeed",
"vertex" : 1
} ],
"operationName" : "1-hop"
}, {
"class" : "Limit",
"resultLimit" : 3,
"truncate" : true
} ]
}
}
Results: