Пример #1
0
		protected void Init(MessageQueue.MessageDelegate processor, DictParams paramlist, int priority, bool parallel)
		{
			vProcessor = processor;
			Parameters = paramlist;
			IsParallel = parallel;
			Priorty = priority;
			
		}
Пример #2
0
		public virtual void Process(MessageQueue msgQueue)
		{
			if (IsValid)
			{
				if (IsParallel)
				{
					vStatus = MessageStatus.ParallelProcessing;
				}
				else
				{
					vStatus = MessageStatus.Processing;
				}
				vProcessor(msgQueue, this);
			}
		}
Пример #3
0
		public Message(MessageQueue.MessageDelegate processor, DictParams paramlist, int priority, bool parallel)
		{
			Init(processor, paramlist, priority, parallel);
		}
Пример #4
0
		public override void Process(MessageQueue msgQueue)
		{
			if (IsValid)
			{
				if (IsParallel)
				{
					vStatus = MessageStatus.ParallelProcessing;
				}
				else
				{
					vStatus = MessageStatus.Processing;
				}
				if (elapsedProcessor != null)
				{
					msgTimer.Elapsed += new ElapsedEventHandler(elapsedProcessor);
					msgTimer.Enabled = true;
					msgTimer.Param = this;
					msgTimer.DictParams = Parameters;
					msgTimer.Start();
				}
			}
		}