/// <summary> /// Sends a CloseChannel message to a store. /// </summary> /// <param name="id">The channel identifier.</param> /// <param name="reason">The close reason.</param> /// <returns>The message identifier.</returns> public virtual long CloseChannel(long id, string reason) { var header = CreateMessageHeader(Protocols.ChannelDataLoad, MessageTypes.ChannelDataLoad.CloseChannel); var message = new CloseChannel { Id = id, CloseReason = reason }; return(Session.SendMessage(header, message)); }
/// <summary> /// Handles the CloseChannel message from a customer. /// </summary> /// <param name="header">The message header.</param> /// <param name="message">The CloseChannel message.</param> protected virtual void HandleCloseChannel(IMessageHeader header, CloseChannel message) { Notify(OnCloseChannel, header, message); }