DecoratedGroupNode.java 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. package ui.model;
  2. import java.util.ArrayList;
  3. import classes.CpsNode;
  4. import classes.CpsUpperNode;
  5. import classes.ExitCable;
  6. import classes.ExitCableV2;
  7. /**
  8. * For the @VisualRepresentationalState only.
  9. * @author Tom
  10. *
  11. */
  12. public class DecoratedGroupNode {
  13. private CpsUpperNode model;
  14. private ArrayList<Supplier> supplierList;
  15. private ArrayList<Passiv> passivList;
  16. private ArrayList<Consumer> consumerList;
  17. private ArrayList<CpsNode> nodeList;
  18. /**
  19. * Cables that only exist on that group node. From a object in that group node to a object in that group Node.
  20. * Not exit the group node (a layer down).
  21. */
  22. private ArrayList<DecoratedCable> internCableList;
  23. /**
  24. * Cables that exit this group node (a Layer Up). From a object in this group node to a object in a upper layer.
  25. */
  26. private ArrayList<ExitCableV2> exitCableList;
  27. private ArrayList<DecoratedSwitch> switchList;
  28. private ArrayList<DecoratedGroupNode> groupNodeList;
  29. public DecoratedGroupNode(CpsUpperNode model, ArrayList<Supplier> supplierList, ArrayList<Passiv> passivList,
  30. ArrayList<Consumer> consumerList, ArrayList<CpsNode> nodeList, ArrayList<DecoratedCable> internCableList,
  31. ArrayList<ExitCableV2> exitCableList, ArrayList<DecoratedSwitch> switchList,
  32. ArrayList<DecoratedGroupNode> groupNodeList) {
  33. this.model = model;
  34. this.supplierList = supplierList;
  35. this.passivList = passivList;
  36. this.consumerList = consumerList;
  37. this.nodeList = nodeList;
  38. this.internCableList = internCableList;
  39. this.exitCableList = exitCableList;
  40. this.switchList = switchList;
  41. this.groupNodeList = groupNodeList;
  42. }
  43. public DecoratedGroupNode(CpsUpperNode model) {
  44. this.model = model;
  45. this.supplierList = new ArrayList<Supplier>();
  46. this.passivList = new ArrayList<Passiv>();
  47. this.consumerList = new ArrayList<Consumer>();
  48. this.nodeList = new ArrayList<CpsNode>();
  49. this.internCableList = new ArrayList<DecoratedCable>();
  50. this.exitCableList = new ArrayList<ExitCableV2>();
  51. this.switchList = new ArrayList<DecoratedSwitch>();
  52. this.groupNodeList = new ArrayList<DecoratedGroupNode>();
  53. }
  54. public CpsUpperNode getModel() {
  55. return model;
  56. }
  57. public ArrayList<Supplier> getSupplierList() {
  58. return supplierList;
  59. }
  60. public ArrayList<Passiv> getPassivList() {
  61. return passivList;
  62. }
  63. public ArrayList<Consumer> getConsumerList() {
  64. return consumerList;
  65. }
  66. public ArrayList<CpsNode> getNodeList() {
  67. return nodeList;
  68. }
  69. public ArrayList<DecoratedCable> getInternCableList() {
  70. return internCableList;
  71. }
  72. public ArrayList<ExitCableV2> getExitCableList() {
  73. return exitCableList;
  74. }
  75. public ArrayList<DecoratedSwitch> getSwitchList() {
  76. return switchList;
  77. }
  78. public ArrayList<DecoratedGroupNode> getGroupNodeList() {
  79. return groupNodeList;
  80. }
  81. }