subscribeToVariable method
Implementation
Stream<dynamic> subscribeToVariable(StateVariable v) {
final id = v.getGenericId();
StateSubscription? sub;
if (_subs.containsKey(id)) {
sub = _subs[id];
} else {
sub = _subs[id] = StateSubscription();
sub.eventUrl = v.service.eventSubUrl;
sub.lastStateVariable = v;
sub.manager = this;
sub.init();
}
return sub!._controller!.stream;
}