setWritable method
Implementation
Future<bool> setWritable(bool writable) {
var completer = Completer<bool>();
dsBridge.callHandler("room.setWritable", [writable], ([value]) {
var error = WhiteException.parseValueError(value);
if (error == null) {
bool isWritable = jsonDecode(value)['isWritable'];
int observerId = jsonDecode(value)['observerId'];
_setWritable(isWritable);
_setObserverId(observerId);
completer.complete(isWritable);
} else {
completer.completeError(error);
}
});
return completer.future;
}