EventMapping.java 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. package com.udapsoft.waf.system.handler.dao;
  2. import java.io.Serializable;
  3. import java.util.List;
  4. public class EventMapping implements Serializable {
  5. private static final long serialVersionUID = 6951746767605267246L;
  6. private String screen;
  7. private String event;
  8. private List<?> bizs;
  9. public EventMapping(String screen, String event, List<?> bizs) {
  10. super();
  11. this.screen = screen;
  12. this.event = event;
  13. this.bizs = bizs;
  14. }
  15. public String getName() {
  16. return this.screen;
  17. }
  18. public String getEvent() {
  19. return this.event;
  20. }
  21. public List<?> getBizs() {
  22. return this.bizs;
  23. }
  24. public String getBiz(int index) {
  25. if (this.bizs != null)
  26. return (String) this.bizs.get(index);
  27. return null;
  28. }
  29. public int getBizSize() {
  30. if (this.bizs != null)
  31. return this.bizs.size();
  32. return 0;
  33. }
  34. public String toString() {
  35. String bizs = "";
  36. for (int i = 0; i < this.bizs.size(); i++) {
  37. bizs += (String) this.bizs.get(i);
  38. if (i < (this.bizs.size() - 1))
  39. bizs += ", ";
  40. }
  41. return "[EventMapping: screen=" + this.screen + ", " + "event="
  42. + this.event + ", " + "biz=(" + bizs + ")]";
  43. }
  44. }