ivr流程编辑器

IVRBranch.cs 1.8KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using HySoft.IVRFlowEditor.Model;
  6. using HySoft.IVRFlowEditor.IVRControl;
  7. namespace HySoft.IVRFlowEditor.IVRControlUtility
  8. {
  9. /// <summary>
  10. /// 分支节点
  11. /// </summary>
  12. [IVRAttribute("CELL_BRANCH", Model.IVRSerializerType.节点,2)]
  13. public class IVRBranch : IVRControlBase
  14. {
  15. public IVRBranch(string name)
  16. {
  17. this.Name = name;
  18. base.CtlProperty = new CtlIVRBranch(this);
  19. Branch = new List<IVRBranchVar>();
  20. }
  21. /// <summary>
  22. /// :参与比较的变量。
  23. /// </summary>
  24. [IVRAttribute("Var", Model.IVRSerializerType.元素,2)]
  25. public string Var
  26. { get; set; }
  27. /// <summary>
  28. /// :默认执行的下一节点编号。
  29. /// </summary>
  30. [IVRAttribute("DefaultPos", Model.IVRSerializerType.元素,3, IsPosPoint = true)]
  31. public IVRControlBase DefaultPos
  32. { get; set; }
  33. /// <Branch Value="1" Pos="1" />:罗列出所有与Var字段变量的值匹配时要跳转的 节点编号。例:当Var字段变量为“1”时跳转到 节点1。
  34. [IVRAttribute("Branch", Model.IVRSerializerType.节点,4)]
  35. public List<IVRBranchVar> Branch
  36. { get; set; }
  37. }
  38. [IVRAttribute("Branch", Model.IVRSerializerType.节点,1)]
  39. public class IVRBranchVar
  40. {
  41. public IVRBranchVar()
  42. { Control = new CtlIVRBranchVar(this); }
  43. [IVRAttribute("Value", Model.IVRSerializerType.元素,2)]
  44. public string Value
  45. { get; set; }
  46. [IVRAttribute("Pos", Model.IVRSerializerType.元素,1)]
  47. public string Pos
  48. { get; set; }
  49. public CtlIVRBranchVar Control
  50. { get; set; }
  51. }
  52. }