getChildren method
Implementation
AsyncReply<List<IResource?>> getChildren(IResource resource) {
var rt = new AsyncReply<List<IResource?>>();
sendRequest(IIPPacketAction.ResourceChildren)
..addUint32(resource.instance?.id as int)
..done().then<dynamic>((ar) {
if (ar != null) {
var d = ar[0] as DC;
Codec.parseResourceArray(d, 0, d.length, this).then((resources) {
rt.trigger(resources);
}).error((ex) => rt.triggerError(ex));
} else {
rt.triggerError(Exception("Null response"));
}
});
return rt;
}