This commit is contained in:
crusader
2018-09-05 15:56:04 +09:00
parent 19dda63c8a
commit 4c04ca5132
3 changed files with 14 additions and 5 deletions

View File

@@ -24,6 +24,9 @@ export class ProbeService extends Client {
public constructor() {
super(codec, rwc);
this.connect();
this.notiSubscription = this.notification()
.subscribe((notiCodec: ClientNotificationCodec) => {
console.log(notiCodec.method());
@@ -35,6 +38,12 @@ export class ProbeService extends Client {
});
}
});
this.connectionStatus().subscribe(isConnected => {
if (!isConnected) {
console.log('disconnected');
} else {
console.log('connected');
}
});
}
}