Closed keiono closed 10 years ago
This API should support batch update.
Here is the updated API:
The return value looks like this:
[
{
"visualProperty": "NODE_WIDTH",
"value": 40
}, ..., {}
]
And the BODY should have the following:
[
{
"SUID": 12345,
"view": [
{
"visualProperty": "NODE_WIDTH",
"value": 40
}, ..., {}
]
}, ... {}
]
With this API, users can update any Visual Property values for the view for multiple nodes/edges at once.
Query parameter has been added to selectively get Visual Property value from a view object.
For example, if you want to get node X position, use:
GET /networks/NET_SUID/views/VIEW_SUID/nodes?visualProperty=NODE_X_LOCATION
And this returns:
[ {
"SUID" : 161,
"view" : [ {
"visualProperty" : "NODE_X_LOCATION",
"value" : 42.974062556729564
} ]
}, {
"SUID" : 133,
"view" : [ {
"visualProperty" : "NODE_X_LOCATION",
"value" : 296.2392603106358
} ]
}, {
"SUID" : 181,
"view" : [ {
"visualProperty" : "NODE_X_LOCATION",
"value" : -343.0770086102626
} ]
}, ...
]
If we already have to provide a NODE_SUID or EDGE_SUID why do we also have to provide a SUID in the JSON payload?
PUT /networks/NET_SUID/views/VIEW_SUID/nodes/NODE_SUID
PUT /networks/NET_SUID/views/VIEW_SUID/edges/EDGE_SUID
and
[
{
"SUID": 12345,
"view": [
{
"visualProperty": "NODE_WIDTH",
"value": 40
}, ..., {}
]
}, ... {}
]
What does this SUID refer to?
And can you please regenerate the API documentation in HTML form with the new API endpoints?
Need to support RESTful operations for View objects. This is for setting/getting Visual Property values for the given view object.