1234567891011121314151617181920212223242526272829303132333435363738 |
- using athosRT.Devices.EFEM.ABS;
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace athosRT.Devices.EFEM.Task
- {
- public class QueryEventTask : CheckImp, ITask
- {
- public bool Execute(out string result, params string[] args)
- {
- string device = "System";
- if (!Enum.TryParse<EfemEventType>(args[0], out EfemEventType _))
- {
- result = "PARAM_NG";
- return false;
- }
- if (!Enum.TryParse<EfemEventValue>(args[1], out EfemEventValue _))
- {
- result = "PARAM_NG";
- return false;
- }
- return this.Check<NoReadyPolicy>(device, out result);
- }
- public bool? Monitor(out string result, params string[] args)
- {
- result = "ON";
- EfemEventType result1;
- Enum.TryParse<EfemEventType>(args[0], out result1);
- result = !((SystemServerModule)this.GetEntity("System")).IsEventEnabled(result1) ? string.Format("OFF") : string.Format("ON");
- return new bool?(true);
- }
- }
- }
|