df9d37ad49cf2047cba7b43a213ac4a880c1f1e6.svn-base 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. /*
  2. * Created on 2006-5-29
  3. *
  4. * TODO To change the template for this generated file go to
  5. * Window - Preferences - Java - Code Style - Code Templates
  6. */
  7. package model.setup.constant;
  8. import com.toolkit.tree.TreeNode;
  9. /**
  10. * @author Administrator
  11. *
  12. * TODO To change the template for this generated type comment go to
  13. * Window - Preferences - Java - Code Style - Code Templates
  14. */
  15. public class ConstantTreeNode implements TreeNode{
  16. private String path;
  17. public String MouseEventName = "";
  18. public String NodeOnMouseEvent = "";
  19. public ConstantTreeNode(String[] nodeData, String codeName, String path, String nodeLinkPage) {
  20. this.path = path;
  21. this.nodeData = nodeData;
  22. this.codeName = codeName;
  23. this.nodeLinkPage = nodeLinkPage;
  24. }
  25. private String[] nodeData = null;
  26. private String nodeLinkPage = "";
  27. @SuppressWarnings("unused")
  28. private String codeName = "";
  29. /*
  30. * (non-Javadoc)
  31. *
  32. * @see com.commons.tree.TreeNode#getNodeID()
  33. */
  34. public String getNodeID() {
  35. return nodeData[0];
  36. }
  37. /**
  38. * @param strings
  39. */
  40. public void setNodeData(String[] nodeData) {
  41. this.nodeData = nodeData;
  42. }
  43. /*
  44. * (non-Javadoc)
  45. *
  46. * @see com.commons.tree.TreeNode#getNodeImagePath(boolean)
  47. */
  48. public String getNodeImagePath(boolean leaf) {
  49. return leaf ? path + "/admin/images/tree_images/topic.gif" : "" + path
  50. + "/admin/images/tree_images/toc_closed.gif";
  51. }
  52. /*
  53. * (non-Javadoc)
  54. *
  55. * @see com.commons.tree.TreeNode#getNodeTitle()
  56. */
  57. public String getNodeTitle() {
  58. return nodeData[1];
  59. }
  60. /*
  61. * (non-Javadoc)
  62. *
  63. * @see com.commons.tree.TreeNode#getNodeTitleLink()
  64. */
  65. public String getNodeTitleLink() {
  66. return nodeLinkPage;
  67. }
  68. /*
  69. * (non-Javadoc)
  70. *
  71. * @see com.commons.tree.TreeNode#getNodeOnMouseEvent()
  72. */
  73. public String getMouseEventName() {
  74. return MouseEventName;
  75. }
  76. /*
  77. * (non-Javadoc)
  78. *
  79. * @see com.commons.tree.TreeNode#getNodeOnMouseEvent()
  80. */
  81. public String getNodeOnMouseEvent() {
  82. return NodeOnMouseEvent;
  83. }
  84. public String getNodeType() {
  85. return null;
  86. }
  87. }