DecoratedCable.java 744 B

12345678910111213141516171819202122232425262728293031323334353637
  1. package ui.model;
  2. import classes.Edge;
  3. public class DecoratedCable {
  4. public enum CableState{
  5. Working, Burned
  6. }
  7. private Edge model;
  8. private CableState state;
  9. private float flowEnergy;
  10. private float powerLoss;
  11. public DecoratedCable(Edge edge, CableState state, float flowEnergy, float powerLoss){
  12. this.model = edge;
  13. this.state = state;
  14. this.flowEnergy = flowEnergy;
  15. this.powerLoss = powerLoss;
  16. }
  17. public Edge getModel() {
  18. return model;
  19. }
  20. public CableState getState() {
  21. return state;
  22. }
  23. public float getFlowEnergy() {
  24. return flowEnergy;
  25. }
  26. public float getPowerLoss() {
  27. return powerLoss;
  28. }
  29. public void setFlowEnergy(float flowEnergy) {
  30. this.flowEnergy = flowEnergy;
  31. }
  32. }