public void Unsubscribe(Subsciption subsciption) { PullSubscription pullSubscription = (PullSubscription)subsciption; _handler.Unbind(pullSubscription); _deliveryServer.RemoveSubscription(pullSubscription); _subscriptions.Remove(subsciption.Identifier); subsciption.Dispose(); }
public Subsciption Subscribe(Filter filter, IEnumerable<Selector> selectors, Expires expires, EndpointAddressBuilder susbcriptionManagerEndpointAddress) { PullSubscription subscription = new PullSubscription(Guid.NewGuid().ToString(), _deliveryResourceUri, _eventType, filter, expires, selectors, this); _handler.Bind(subscription, susbcriptionManagerEndpointAddress); _deliveryServer.AddSubscription(subscription); _subscriptions[subscription.Identifier] = subscription; return subscription; }
public Subsciption Subscribe(Filter filter, IEnumerable <Selector> selectors, Expires expires, EndpointAddressBuilder susbcriptionManagerEndpointAddress) { PullSubscription subscription = new PullSubscription(Guid.NewGuid().ToString(), _deliveryResourceUri, _eventType, filter, expires, selectors, this); _handler.Bind(subscription, susbcriptionManagerEndpointAddress); _deliveryServer.AddSubscription(subscription); _subscriptions[subscription.Identifier] = subscription; return(subscription); }
public void RemoveSubscription(PullSubscription subscription) { _subscriptions.Remove(subscription.Identifier); }
public void AddSubscription(PullSubscription subscription) { _subscriptions[subscription.Identifier] = subscription; }