NotifiableIoItem.cs 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Runtime.Serialization;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7. using MECF.Framework.Common.CommonData;
  8. namespace MECF.Framework.Common.IOCore
  9. {
  10. public class NotifiableIoItem : NotifiableItem
  11. {
  12. [DataMember]
  13. public string Name { get; set; }
  14. [DataMember]
  15. public string Description { get; set; }
  16. [DataMember]
  17. public int Index { get; set; }
  18. [DataMember]
  19. public bool BoolValue { get; set; }
  20. [DataMember]
  21. public short ShortValue { get; set; }
  22. [DataMember]
  23. public string Address { get; set; }
  24. [DataMember]
  25. public string Provider { get; set; }
  26. [DataMember]
  27. public int BlockOffset { get; set; }
  28. [DataMember]
  29. public int BlockIndex { get; set; }
  30. [DataMember]
  31. public bool HoldValue { get; set; }
  32. public NotifiableIoItem Clone()
  33. {
  34. return new NotifiableIoItem()
  35. {
  36. Address = Address,
  37. BlockIndex = BlockIndex,
  38. BlockOffset = BlockOffset,
  39. BoolValue = BoolValue,
  40. Description = Description,
  41. HoldValue = HoldValue,
  42. Index = Index,
  43. Name = Name,
  44. Provider = Provider,
  45. ShortValue = ShortValue,
  46. };
  47. }
  48. }
  49. }