+
+ this.sdksSubject.next(this._sdksList);
+ });
+ });
+
+ // Add listener on sdk creation, deletion and change events
+ this.xdsSvr.onSdkInstall().subscribe(evMgt => {
+ this._addSdk(evMgt.sdk);
+ });
+ this.xdsSvr.onSdkRemove().subscribe(evMgt => {
+ if (evMgt.sdk.status !== 'Not Installed') {
+ /* tslint:disable:no-console */
+ console.log('Error: received event:sdk-remove with invalid status: evMgt=', evMgt);
+ return;
+ }
+ this._delSdk(evMgt.sdk);
+ });
+
+ }
+
+ public setCurrent(s: ISdk) {
+ this.current = s;
+ }
+
+ public getCurrent(): ISdk {
+ return this.current;
+ }
+
+ public getCurrentId(): string {
+ if (this.current && this.current.id) {
+ return this.current.id;