Task IPremiseSubscription.UnsubscribeAsync() { var future = new UnsubscribeFuture(_objectId, _subscriptionId); _sysClient.Send(future, out Task task); if (!_sysClient.Subscriptions.TryRemove(clientSideSubscriptionId, out Subscription _)) { Debug.WriteLine($"Subscription {clientSideSubscriptionId} Not Found"); } return(task); }
Task <IPremiseObject> IPremiseObject.CreateObjectAsync(IPremiseObject type, string name) { var future = new CreateObjectFuture(_objectId, (type as PremiseObject)?._objectId, name); _client.Send(future, out Task <IPremiseObject> task); return(task); }