using Edge.Core.Parser; using Edge.Core.Parser.BinaryParser.MessageEntity; using System; using System.Collections.Generic; using System.Linq; using System.Threading; using System.Threading.Tasks; namespace Edge.Core.Processor { public interface IIncoming where TMessage : MessageBase { event EventHandler OnMessageIncoming; /// /// indicates it's been a while that have NOT received any messages incoming from communicator. /// if the incoming has never received a message from the begining(happened at the application just started), /// then this event will NOT fired. /// event EventHandler OnLongTimeNoSeeMessage; /// /// by ms, for control firing the event: OnLongTimeNoSeeMessageIncoming which indicates not received any msg for period time of this value specified. /// 0 will disable the feature. /// int LongTimeNoSeeMessageTimeout { get; set; } /// /// Gets or sets if should notifiy the IHandler a new message is incoming. /// this is a hook for intercept a new message to IHanlder. /// bool DisablePropagate { get; set; } TMessage Message { get; set; } } }