value
: Primitive|Array - the value to store in the node.To create or update a node stored in an API the set
action is used on the
reference to the node. The action is asynchronous, and returns a promise that
resolves if successful. No value is returned to the resolved promise.
var fooRef = new iwc.data.Reference("/foo");
fooRef.set("Hello World!");
Requesting to create/update a node in a read-only API will result in a noPermission
error.
System API and Names API both contain read-only resources
var myApp = new iwc.system.Reference("/application/com.ozone.myApp");
myApp.set("random value").catch(function(err){
//err === "noPermission"
});