InvokeService.cs 987 B

12345678910111213141516171819202122232425262728293031
  1. using System;
  2. using System.ServiceModel;
  3. using System.Text;
  4. using Aitex.Core.RT.Log;
  5. using Aitex.Core.RT.OperationCenter;
  6. namespace MECF.Framework.Common.OperationCenter
  7. {
  8. [ServiceBehavior(InstanceContextMode = InstanceContextMode.Single, ConcurrencyMode = ConcurrencyMode.Multiple)]
  9. public class InvokeService : IInvokeService
  10. {
  11. public void DoOperation(string operationName, params object[] args)
  12. {
  13. try
  14. {
  15. //if (KeyManager.Instance.IsExpired)
  16. //{
  17. // EV.PostMessage("System", EventEnum.DefaultWarning, "Software is expired. Can not do the operation");
  18. // return;
  19. //}
  20. OP.DoOperation(operationName, args);
  21. }
  22. catch (Exception ex)
  23. {
  24. LOG.WriteExeption(string.Format("调用{0},碰到未处理的WCF操作异常", operationName), ex);
  25. }
  26. }
  27. }
  28. }