public Chatroom(string name, IRecipient server) { Name = name; Recipients = new Dictionary <string, IRecipient>(); Recipients.Add("server", server); MessageQueue = new Queue <Message>(); }
/// <summary> /// Проверить наличие у участника прав на сущность. /// </summary> /// <param name="entity">Сущность.</param> /// <param name="member">Участник.</param> /// <param name="accessRightsType">Тип прав.</param> /// <returns>True - если права есть, иначе - false.</returns> public static bool CheckGrantedRights(IEntity entity, IRecipient member, Guid accessRightsType) { if (accessRightsType == DefaultAccessRightsTypes.Change) { return(entity.AccessRights.IsGrantedDirectly(accessRightsType, member) || entity.AccessRights.IsGrantedDirectly(DefaultAccessRightsTypes.FullAccess, member)); } if (accessRightsType == Docflow.Constants.Module.DefaultAccessRightsTypeSid.ChangeContent) { return(entity.AccessRights.IsGrantedDirectly(accessRightsType, member) || entity.AccessRights.IsGrantedDirectly(DefaultAccessRightsTypes.Change, member) || entity.AccessRights.IsGrantedDirectly(DefaultAccessRightsTypes.FullAccess, member)); } if (accessRightsType == DefaultAccessRightsTypes.Read) { return(entity.AccessRights.IsGrantedDirectly(accessRightsType, member) || entity.AccessRights.IsGrantedDirectly(DefaultAccessRightsTypes.FullAccess, member) || entity.AccessRights.IsGrantedDirectly(DefaultAccessRightsTypes.Change, member) || entity.AccessRights.IsGrantedDirectly(Docflow.Constants.Module.DefaultAccessRightsTypeSid.ChangeContent, member)); } return(entity.AccessRights.IsGrantedDirectly(accessRightsType, member)); }
public NotifyRequest(INotifySource notifySource, INotifyAction action, string objectID, IRecipient recipient) { if (notifySource == null) { throw new ArgumentNullException("notifySource"); } if (action == null) { throw new ArgumentNullException("action"); } if (recipient == null) { throw new ArgumentNullException("recipient"); } Properties = new Hashtable(); Arguments = new List <ITagValue>(); RequaredTags = new List <string>(); Interceptors = new List <ISendInterceptor>(); NotifySource = notifySource; Recipient = recipient; NotifyAction = action; ObjectID = objectID; IsNeedCheckSubscriptions = true; }
public string[] GetSubscriptionMethod(INotifyAction action, IRecipient recipient) { if (action == null) throw new ArgumentNullException("action"); if (recipient == null) throw new ArgumentNullException("recipient"); return subscriptionManager.GetSubscriptionMethod(sourceID, action.ID, recipient.ID); }
public void Subscribe(INotifyAction action, string objectID, IRecipient recipient) { if (action == null) throw new ArgumentNullException("action"); if (recipient == null) throw new ArgumentNullException("recipient"); subscriptionManager.Subscribe(sourceID, action.ID, objectID, recipient.ID); }
public SendResponse(INotifyAction action, string senderName, IRecipient recipient, SendResult sendResult) { SenderName = senderName; Recipient = recipient; Result = sendResult; NotifyAction = action; }
public string[] GetSubscriptions(INotifyAction action, IRecipient recipient, bool checkSubscribe = true) { if (action == null) throw new ArgumentNullException("action"); if (recipient == null) throw new ArgumentNullException("recipient"); return subscriptionManager.GetSubscriptions(sourceID, action.ID, recipient.ID, checkSubscribe); }
/// <summary> /// Call the registered data handlers. /// </summary> /// <param name="data">The received data.</param> /// <param name="recipient">The sender of the data.</param> protected void HandleReceivedData(byte[] data, IRecipient sender) { foreach (IDataHandler handler in _dataHandlers) { handler.Handle(data, sender); } }
public virtual string[] GetSubscriptionMethod(INotifyAction action, IRecipient recipient) { if (action == null) { throw new ArgumentNullException("action"); } if (recipient == null) { throw new ArgumentNullException("recipient"); } var senders = subscriptionProvider.GetSubscriptionMethod(action, recipient); if (senders == null || senders.Length == 0) { var parents = WalkUp(recipient); foreach (var parent in parents) { senders = subscriptionProvider.GetSubscriptionMethod(action, parent); if (senders != null && senders.Length != 0) { break; } } } return(senders != null && 0 < senders.Length ? senders : defaultSenderMethods); }
private NotifyRequest CreateRequest(INotifyAction action, string objectID, IRecipient recipient, SendNoticeCallback sendCallback, ITagValue[] args, string[] senders, bool checkSubsciption) { if (action == null) { throw new ArgumentNullException("action"); } if (recipient == null) { throw new ArgumentNullException("recipient"); } if (sendCallback != null) { throw new NotImplementedException("sendCallback"); } var request = new NotifyRequest(notifySource, action, objectID, recipient); request.SenderNames = senders; request.IsNeedCheckSubscriptions = checkSubsciption; if (args != null) { request.Arguments.AddRange(args); } return(request); }
/// <summary> /// Deletes a recipient from an envelope. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='envelopeId'> /// The id of the envelope/bulk. /// </param> /// <param name='recipientId'> /// The id of an recipient in the bulk or envelope. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <object> DeleteRecipientAsync(this IRecipient operations, string envelopeId, string recipientId, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.DeleteRecipientWithHttpMessagesAsync(envelopeId, recipientId, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
public SendResponse(INotifyAction action, IRecipient recipient, Exception exc) { Result = SendResult.Impossible; Exception = exc; Recipient = recipient; NotifyAction = action; }
public virtual IRecipientsGroup[] GetGroups(IRecipient recipient) { if (recipient == null) throw new ArgumentNullException("recipient"); var result = new List<IRecipientsGroup>(); var recID = Guid.Empty; if (TryParseGuid(recipient.ID, out recID)) { if (recipient is IRecipientsGroup) { var group = CoreContext.GroupManager.GetGroupInfo(recID); while (group != null && group.Parent != null) { result.Add(new RecipientsGroup(group.Parent.ID.ToString(), group.Parent.Name)); group = group.Parent; break; } } else if (recipient is IDirectRecipient) { foreach (var group in CoreContext.UserManager.GetUserGroups(recID, IncludeType.Distinct)) { result.Add(new RecipientsGroup(group.ID.ToString(), group.Name)); } } } return result.ToArray(); }
/// <summary> /// Responding event handler. Checks if a send-as address must be specified. /// </summary> /// <param name="mail"></param> /// <param name="response"></param> private void MailEvents_Respond(IMailItem mail, IMailItem response) { Logger.Instance.Trace(this, "Responding to mail, checking"); using (IStore store = mail.GetStore()) { ZPushAccount zpush = Watcher.Accounts.GetAccount(store); Logger.Instance.Trace(this, "Checking ZPush: {0}", zpush); if (zpush == null) { return; } // Check if the containing folder is a shared folder using (IFolder parent = mail.Parent) using (IRecipient recip = FindSendAsSender(zpush, parent)) { if (recip == null || !recip.IsResolved) { return; } // Set the sender Logger.Instance.Trace(this, "Sending as: {0}", recip.Address); using (IAddressEntry address = recip.GetAddressEntry()) { response.SetSender(address); } } } }
public virtual IRecipientsGroup[] GetGroups(Tenant tenant, IRecipient recipient) { if (recipient == null) { throw new ArgumentNullException("recipient"); } var result = new List <IRecipientsGroup>(); if (TryParseGuid(recipient.ID, out var recID)) { if (recipient is IRecipientsGroup) { var group = CoreContext.UserManager.GetGroupInfo(tenant.TenantId, recID); while (group != null && group.Parent != null) { result.Add(new RecipientsGroup(group.Parent.ID.ToString(), group.Parent.Name)); group = group.Parent; } } else if (recipient is IDirectRecipient) { foreach (var group in CoreContext.UserManager.GetUserGroups(tenant, recID, IncludeType.Distinct)) { result.Add(new RecipientsGroup(group.ID.ToString(), group.Name)); } } } return(result.ToArray()); }
public virtual object GetSubscriptionRecord(INotifyAction action, IRecipient recipient, string objectID) { if (recipient == null) { throw new ArgumentNullException("recipient"); } if (action == null) { throw new ArgumentNullException("action"); } var subscriptionRecord = subscriptionProvider.GetSubscriptionRecord(action, recipient, objectID); if (subscriptionRecord != null) { return(subscriptionRecord); } var parents = WalkUp(recipient); foreach (var parent in parents) { subscriptionRecord = subscriptionProvider.GetSubscriptionRecord(action, parent, objectID); if (subscriptionRecord != null) { break; } } return(subscriptionRecord); }
/// <summary> /// Получить представление исполнителя. /// </summary> /// <param name="recipient">Роль/сотрудник.</param> /// <returns>Представление.</returns> public static string GetRecipientDescription(IRecipient recipient) { var result = string.Empty; var employee = Employees.As(recipient); if (employee != null) { result = Functions.ApprovalStage.GetEmployeePresentation(employee); } else { var group = Sungero.CoreEntities.Groups.As(recipient); if (group != null) { var employees = Docflow.PublicFunctions.Module.Remote.GetEmployeesFromRecipientsRemote(new List <IRecipient> { recipient }).Distinct(); List <string> employeesDescription = employees.Select(e => Functions.ApprovalStage.GetEmployeePresentation(e)).ToList(); result = string.Join(string.Format("{0}{1}", ",", Environment.NewLine), employeesDescription); result = string.Format("\"{0}\" ({1})", recipient.Name, result); } else { result = string.Format("\"{0}\"", recipient.Name); } } return(result); }
public IMessageBuilder AddToRecipient(IRecipient recipient, JObject recipientVariables = null) { //check for recipient ThrowIf.IsArgumentNull(() => recipient); if (_recipientCount == Constants.MaximumAllowedRecipients) { throw new Exception("Messages cannot contain more than To 1000 recipients"); } //set the to value if (_message.To == null) { _message.To = new Collection <IRecipient>(); } //set the recipient variables if (recipientVariables != null) { if (_message.RecipientVariables == null) { _message.RecipientVariables = new JObject(); } _message.RecipientVariables[recipient.Email] = recipientVariables; } //add to the message _message.To.Add(recipient); _recipientCount++; return(this); }
public RecipientBillHistory(IRecipient recipient, IBillService service) { _billservice = service; this.RecipientId = recipient.RecipientId; this.RecipientName = recipient.CompanyName; _billservice.GetBillsForMonth(); }
/// <summary> /// Handle received data, parse the message and pass it to the registered handlers. /// </summary> /// <param name="data">The received data.</param> /// <param name="recipient">The sender of the data.</param> async public void Handle(byte[] data, IRecipient sender) { // Check if the data contains at least the message type id. if (data.Length < sizeof(int)) { return; } IPacket packet = ParsePacket(data); IMessageType type = TypeConfig.GetTypeById(packet.MessageType); if (type == null || type.Serializer == null) { return; } object obj = type.Serializer.Deserialize(packet.Payload); if (obj is IAcknowledgeRequest) { var message = (IAcknowledgeRequest)obj; await Send(sender, new AcknowledgeResponse(message.AckToken)); } if (obj is IAcknowledgeResponse) { var response = (IAcknowledgeResponse)obj; _pendingAcknowledgeRequests.TryRemove(response.AckToken, out PendingAcknowledgeRequest removed); } type.Handler?.Handle(obj); }
public virtual void Subscribe(INotifyAction action, string objectID, IRecipient recipient) { if (action == null) throw new ArgumentNullException("action"); if (recipient == null) throw new ArgumentNullException("recipient"); subscriptionProvider.Subscribe(action, objectID, recipient); }
public GetPeopleAndRecipient( IPersonConnection people, IRecipient personById) { People = people; PersonById = personById; }
public Notifier(IEnumerable <IClient> clients) { _clients = clients; _message = new Message(); _recipient = new Recipient(); }
public IEmailAdditional BaseBuildEmail(IRecipient recipient, string body) => new AdditionalBaseEmailBuilder(new Email { Recipients = new List <IRecipient> { recipient }, Body = body });
public ChatMessage(IUser sender, IRecipient recipient, string content) { Sender = sender; Recipient = recipient; Content = content; TimeStamp = DateTime.Now; }
private bool IsSubscribeToWhatsNew(IRecipient recipient) { if (recipient == null) { return(false); } return(source.GetSubscriptionProvider().IsSubscribed(Constants.ActionSendWhatsNew, recipient, null)); }
public static bool IsSubscribed(this ISubscriptionProvider provider, INotifyAction action, IRecipient recipient, string objectID) { return Array.Exists( provider.GetSubscriptions(action, recipient), id => id == objectID || (string.IsNullOrEmpty(id) && string.IsNullOrEmpty(objectID)) ); }
public IAdvancedEmailBuilder BuildBaseEmail(IRecipient recipient, string body) => new AdvancedClassicEmailBuilder(new Email { Recipients = new List <IRecipient> { recipient }, Body = body });
public virtual void UnSubscribe(INotifyAction action, IRecipient recipient) { string[] objects = GetSubscriptions(action, recipient); foreach (string objectID in objects) { _directSubscriptionProvider.UnSubscribe(action, objectID, recipient); } }
public RecipientVM(IRecipient recipient) { this.Account = recipient.Account; this.RecipientId = recipient.RecipientId; this.CompanyName = recipient.CompanyName; this.Address = recipient.Address; this.CustomerServiceUrl = recipient.CustomerServiceUrl; this.Active = recipient.Active; }
public virtual void UnSubscribe(Tenant tenant, INotifyAction action, IRecipient recipient) { var objects = GetSubscriptions(tenant, action, recipient); foreach (var objectID in objects) { subscriptionProvider.UnSubscribe(action, objectID, recipient); } }
public IMessageBuilder SetFromAddress(IRecipient sender) { //check for recipient ThrowIf.IsArgumentNull(() => sender); //add to the message _message.From = sender; return(this); }
public Task SendAsync(IdentityMessage message, IRecipient fromAddress) { ThrowIf.IsArgumentNull(() => message); ThrowIf.IsArgumentNull(() => fromAddress); //set from address _from = fromAddress; return(_options != null?SendWithOptions(message) : SendWithSimpleParameters(message)); }
public void UpdateRecepient(IRecipient recipient) { DbAccess.Entities.Recipient dbrecipient = this.repo.GetById(recipient.RecipientId); dbrecipient.Account = recipient.Account; dbrecipient.Address = recipient.Address; dbrecipient.CompanyName = recipient.CompanyName; dbrecipient.CustomerServiceUrl = recipient.CustomerServiceUrl; dbrecipient.Active = true; this.repo.Update(dbrecipient); this.repo.Save(); }
/// <summary> /// Return a CmsTypedStream representing the content in the EnvelopedData after recovering the content /// encryption/MAC key using the passed in Recipient. /// </summary> /// <param name="recipient">Recipient object to use to recover content encryption key</param> /// <returns>The content inside the EnvelopedData this RecipientInformation is associated with.</returns> public CmsTypedStream GetContentStream(IRecipient recipient) { op = GetRecipientOperator(recipient); if (additionalData != null) { return(new CmsTypedStream(secureReadable.GetInputStream())); } return(new CmsTypedStream(op.GetStream(secureReadable.GetInputStream()))); }
public void UpdateSubscriptionMethod(INotifyAction action, IRecipient recipient, params string[] senderNames) { if (action == null) { throw new ArgumentNullException("action"); } if (recipient == null) { throw new ArgumentNullException("recipient"); } subscriptionManager.UpdateSubscriptionMethod(sourceID, action.ID, recipient.ID, senderNames); }
public void CreateProviders() { tenant = new Tenants.Tenant(0, "teamlab"); sourceId = "6045b68c-2c2e-42db-9e53-c272e814c4ad"; actionId = "NewCommentForTask"; objectId = "Task_5946_457"; nAction = new NotifyAction(actionId, actionId); testRec = new DirectRecipient("ff0c4e13-1831-43c2-91ce-7b7beb56179b", null); //Oliver Khan testRec2 = new DirectRecipient("0017794f-aeb7-49a5-8817-9e870e02bd3f", null); //Якутова Юлия recProvider = new RecipientProviderImpl(); var directSubProvider = new DirectSubscriptionProvider(sourceId, CoreContext.SubscriptionManager, recProvider, null); subProvider = new TopSubscriptionProvider(recProvider, directSubProvider); CoreContext.TenantManager.SetCurrentTenant(tenant); }
public NotifyRequest(INotifySource notifySource, INotifyAction action, string objectID, IRecipient recipient) { if (notifySource == null) throw new ArgumentNullException("notifySource"); if (action == null) throw new ArgumentNullException("action"); if (recipient == null) throw new ArgumentNullException("recipient"); Properties = new Hashtable(); Arguments = new List<ITagValue>(); RequaredTags = new List<string>(); Interceptors = new List<ISendInterceptor>(); NotifySource = notifySource; Recipient = recipient; NotifyAction = action; ObjectID = objectID; IsNeedCheckSubscriptions = true; }
public virtual string[] GetSubscriptionMethod(INotifyAction action, IRecipient recipient) { if (action == null) throw new ArgumentNullException("action"); if (recipient == null) throw new ArgumentNullException("recipient"); var senders = subscriptionProvider.GetSubscriptionMethod(action, recipient); if (senders == null || senders.Length == 0) { var parents = WalkUp(recipient); foreach (var parent in parents) { senders = subscriptionProvider.GetSubscriptionMethod(action, parent); if (senders != null && senders.Length != 0) break; } } return senders != null && 0 < senders.Length ? senders : defaultSenderMethods; }
public virtual string[] GetSubscriptionMethod(INotifyAction action, IRecipient recipient) { if (action == null) throw new ArgumentNullException("action"); if (recipient == null) throw new ArgumentNullException("recipient"); string[] senders = _directSubscriptionProvider.GetSubscriptionMethod(action, recipient); if (senders == null || senders.Length == 0) { List<IRecipient> parents = WalkUp(recipient); foreach (IRecipient parent in parents) { senders = _directSubscriptionProvider.GetSubscriptionMethod(action, parent); if (senders != null && senders.Length != 0) break; } } if (senders == null || senders.Length == 0) senders = _defaultSenderMethods; return senders; }
private NotifyRequest CreateRequest(INotifyAction action, string objectID, IRecipient recipient, SendNoticeCallback sendCallback, ITagValue[] args, string[] senders, bool checkSubsciption) { if (action == null) throw new ArgumentNullException("action"); if (recipient == null) throw new ArgumentNullException("recipient"); if (sendCallback != null) throw new NotImplementedException("sendCallback"); var request = new NotifyRequest(notifySource, action, objectID, recipient); request.SenderNames = senders; request.IsNeedCheckSubscriptions = checkSubsciption; if (args != null) request.Arguments.AddRange(args); return request; }
public void UpdateSubscriptionMethod(INotifyAction action, IRecipient recipient, params string[] senderNames) { provider.UpdateSubscriptionMethod(GetAdminAction(action), recipient, senderNames); }
internal NotifyRequest Split(IRecipient recipient) { if (recipient == null) throw new ArgumentNullException("recipient"); var newRequest = new NotifyRequest(NotifySource, NotifyAction, ObjectID, recipient); newRequest.SenderNames = SenderNames; newRequest.Patterns = Patterns; newRequest.Arguments = new List<ITagValue>(Arguments); newRequest.RequaredTags = RequaredTags; newRequest.CurrentSender = CurrentSender; newRequest.CurrentMessage = CurrentMessage; newRequest.Interceptors.AddRange(Interceptors); return newRequest; }
public string[] GetSubscriptionMethod(INotifyAction action, IRecipient recipient) { return provider.GetSubscriptionMethod(GetAdminAction(action), recipient); }
public IRecipientsGroup[] GetGroups(IRecipient recipient, string objectID) { return GetGroups(recipient); }
public void UnSubscribe(INotifyAction action, string objectID, IRecipient recipient) { provider.UnSubscribe(GetAdminAction(action), objectID, recipient); }
private void SendNoticeToAsync(INotifyAction action, string objectID, IRecipient[] recipients, string[] senderNames, SendNoticeCallback sendCallback, bool checkSubsciption, params ITagValue[] args) { if (recipients == null) throw new ArgumentNullException("recipients"); BeginSingleRecipientEvent("__syspreventduplicateinterceptor"); foreach (var recipient in recipients) { var r = CreateRequest(action, objectID, recipient, sendCallback, args, senderNames, checkSubsciption); SendAsync(r); } }
internal List<IRecipient> WalkUp(IRecipient recipient) { var parents = new List<IRecipient>(); IRecipientsGroup[] groups = _recipientProvider.GetGroups(recipient) ?? new IRecipientsGroup[0]; foreach (IRecipientsGroup group in groups) { parents.Add(group); List<IRecipient> topgroups = WalkUp(group); parents.AddRange(topgroups); } return parents; }
public void SendNoticeToAsync(INotifyAction action, string objectID, IRecipient[] recipients, string[] senderNames, SendNoticeCallback sendCallback, params ITagValue[] args) { SendNoticeToAsync(action, objectID, recipients, senderNames, sendCallback, false, args); }
public void SendNoticeAsync(INotifyAction action, string objectID, IRecipient recipient, SendNoticeCallback sendCallback, params ITagValue[] args) { SendNoticeToAsync(action, objectID, new[] { recipient }, null, sendCallback, false, args); }
private string[] GetDefaultSenders(IRecipient recipient) { return source.GetSubscriptionProvider().GetSubscriptionMethod( NotifyConstants.Event_NewCommentForMessage, recipient); }
public void SendNoticeAsync(INotifyAction action, string objectID, IRecipient recipient, bool checkSubscription, params ITagValue[] args) { SendNoticeToAsync(action, objectID, new[] { recipient }, null, null, checkSubscription, args); }
private bool IsSubscribeToWhatsNew(IRecipient recipient) { if (recipient == null) return false; return source.GetSubscriptionProvider().IsSubscribed(Constants.ActionSendWhatsNew, recipient, null); }
public void UnSubscribe(INotifyAction action, IRecipient recipient) { provider.UnSubscribe(GetAdminAction(action), recipient); }
public void TopSubProviderTest() { try { //0017794f-aeb7-49a5-8817-9e870e02bd3f - Якутова Юлия //ff0c4e13-1831-43c2-91ce-7b7beb56179b - Oliver Khan //cc8eea30-1260-427e-83c4-ff9e9680edba - Отдел интернет-приложений!!!;) IRecipient[] res; //GetRecipients res = subProvider.GetRecipients(nAction, objectId); var cnt = res.Count(); //Subscribe subProvider.Subscribe(nAction, objectId, testRec); res = subProvider.GetRecipients(nAction, objectId); Assert.AreEqual(cnt + 1, res.Count()); //UnSubscribe subProvider.UnSubscribe(nAction, testRec); res = subProvider.GetRecipients(nAction, objectId); Assert.AreEqual(cnt, res.Count()); String[] objs; //GetSubscribtions //Получаем подписки юзера //for (int i = 0; i < 6; i++) subProvider.Subscribe(nAction, new Random().Next().ToString(), testRec2); objs = subProvider.GetSubscriptions(nAction, testRec2); CollectionAssert.IsNotEmpty(objs); CollectionAssert.AllItemsAreUnique(objs); //Получаем список групп к которым он принадлежит var parents = recProvider.GetGroups(testRec2); CollectionAssert.IsNotEmpty(parents); otdel = parents.First(); everyone = parents.Last(); var objsGroup = subProvider.GetSubscriptions(nAction, otdel); CollectionAssert.AllItemsAreUnique(objsGroup); //Подписываем весь отдел на объект rndObj = String.Concat("TestObject#", new Random().Next().ToString()); subProvider.Subscribe(nAction, rndObj, otdel); //Проверяем подписался ли юзер вместе со всем отделом двумя способами. Assert.AreEqual(objsGroup.Count() + 1, subProvider.GetSubscriptions(nAction, otdel).Count()); Assert.AreEqual(objs.Count() + 1, subProvider.GetSubscriptions(nAction, testRec2).Count()); Assert.AreEqual(true, subProvider.IsSubscribed(nAction, testRec2, rndObj)); //Подписываем Everybody rndObj2 = String.Concat("TestObject#", new Random().Next().ToString()); objs = subProvider.GetSubscriptions(nAction, testRec2); subProvider.Subscribe(nAction, rndObj2, everyone); //Проверяем подписался ли user двумя способами. Assert.AreEqual(objs.Count() + 1, subProvider.GetSubscriptions(nAction, testRec2).Count()); Assert.AreEqual(true, subProvider.IsSubscribed(nAction, testRec2, rndObj2)); } finally { subProvider.UnSubscribe(nAction, objectId, testRec); subProvider.UnSubscribe(nAction, rndObj, otdel); subProvider.UnSubscribe(nAction, rndObj2, everyone); } }
public string[] GetSubscriptions(INotifyAction action, IRecipient recipient, bool checkSubscription = true) { return provider.GetSubscriptions(GetAdminAction(action), recipient, checkSubscription); }
public void UnSubscribe(INotifyAction action, IRecipient recipient) { throw new NotSupportedException("use UnSubscribe(INotifyAction, string, IRecipient )"); }
public void UpdateSubscriptionMethod(INotifyAction action, IRecipient recipient, params string[] senderNames) { if (action == null) throw new ArgumentNullException("action"); if (recipient == null) throw new ArgumentNullException("recipient"); subscriptionManager.UpdateSubscriptionMethod(sourceID, action.ID, recipient.ID, senderNames); }