001: package com.salmonllc.xml;
002:
003: /////////////////////////
004: //$Archive: /JADE/SourceCode/com/salmonllc/xml/TreeItem.java $
005: //$Author: Srufle $
006: //$Revision: 7 $
007: //$Modtime: 7/31/02 7:13p $
008: /////////////////////////
009: /**
010: * This datastructure is used to store a node of a tree. Every TreeItem, node, may or may not contain many TreeItemAddImage objects.
011: * Creation date: (8/21/01 4:53:39 PM)
012: * @author: Deepak Agarwal
013: */
014: public class TreeItem extends Tree {
015:
016: private String fieldText = "";
017: private String fieldImgSource = "";
018: private String fieldImgExpSource = "";
019: private String fieldHref = "";
020: private String fieldImgHref = "";
021: private String fieldName = "";
022: private boolean fieldVisible = true;
023: private java.util.Vector fieldAddImages = new java.util.Vector();
024:
025: /**
026: * TreeItem constructor comment.
027: */
028: public TreeItem() {
029: super ();
030: }
031:
032: /**
033: * This method returns the images for a Tree Node
034: * Creation date: (8/22/01 9:33:32 AM)
035: * @return java.util.Vector
036: */
037: public java.util.Vector getAddImages() {
038: return fieldAddImages;
039: }
040:
041: /**
042: * Gets the link href, if specified for a tree node
043: * Creation date: (8/21/01 4:56:43 PM)
044: * @return java.lang.String
045: */
046: public java.lang.String getHref() {
047: return fieldHref;
048: }
049:
050: /**
051: * Gets the expand image source file name for a Tree Node
052: * Creation date: (8/21/01 4:56:43 PM)
053: * @return java.lang.String
054: */
055: public java.lang.String getImgExpSource() {
056: return fieldImgExpSource;
057: }
058:
059: /**
060: * Gets the image source file name for a Tree Node
061: * Creation date: (8/21/01 4:56:43 PM)
062: * @return java.lang.String
063: */
064: public java.lang.String getImgHref() {
065: return fieldImgHref;
066: }
067:
068: /**
069: * Gets the image source file name for a Tree Node
070: * Creation date: (8/21/01 4:56:43 PM)
071: * @return java.lang.String
072: */
073: public java.lang.String getImgSource() {
074: return fieldImgSource;
075: }
076:
077: /**
078: * Gets the name for the TreeItem component
079: * Creation date: (8/21/01 4:57:14 PM)
080: * @return java.lang.String
081: */
082: public java.lang.String getName() {
083: return fieldName;
084: }
085:
086: /**
087: * Gets the text used to display on Tree node
088: * Creation date: (8/21/01 4:56:43 PM)
089: * @return java.lang.String
090: */
091: public java.lang.String getText() {
092: return fieldText;
093: }
094:
095: /**
096: * Gets the flag 'Visible' for Tree Tag
097: * Creation date: (8/21/01 4:59:17 PM)
098: * @return boolean
099: */
100: public boolean isVisible() {
101: return fieldVisible;
102: }
103:
104: /**
105: * Sets the additinal images used by a Tree Node
106: * Creation date: (8/22/01 9:33:32 AM)
107: * @param newAddImages java.util.Vector
108: */
109: public void setAddImages(java.util.Vector newAddImages) {
110: fieldAddImages = newAddImages;
111: }
112:
113: /**
114: * Sets the Href link for Tree node
115: * Creation date: (8/21/01 4:56:43 PM)
116: * @param newHref java.lang.String
117: */
118: public void setHref(java.lang.String newHref) {
119: fieldHref = newHref;
120: }
121:
122: /**
123: * Creation date: (8/21/01 4:56:43 PM)
124: * @param newImgExpSource java.lang.String
125: */
126: public void setImgExpSource(java.lang.String newImgExpSource) {
127: fieldImgExpSource = newImgExpSource;
128: }
129:
130: /**
131: * Sets the Href link for Image on Tree node
132: * Creation date: (8/21/01 4:56:43 PM)
133: * @param newImgHref java.lang.String
134: */
135: public void setImgHref(java.lang.String newImgHref) {
136: fieldImgHref = newImgHref;
137: }
138:
139: /**
140: * Sets the Href link for Image on Tree node
141: * Creation date: (8/21/01 4:56:43 PM)
142: * @param newImgSource java.lang.String
143: */
144: public void setImgSource(java.lang.String newImgSource) {
145: fieldImgSource = newImgSource;
146: }
147:
148: /**
149: * Sets the name of the component
150: * Creation date: (8/21/01 4:57:14 PM)
151: * @param newName java.lang.String
152: */
153: public void setName(java.lang.String newName) {
154: fieldName = newName;
155: }
156:
157: /**
158: * Sets the text used by component
159: * Creation date: (8/21/01 4:56:43 PM)
160: * @param newText java.lang.String
161: */
162: public void setText(java.lang.String newText) {
163: fieldText = newText;
164: }
165:
166: /**
167: * Sets the visibility of Tree Node
168: * Creation date: (8/21/01 4:59:17 PM)
169: * @param newVisible boolean
170: */
171: public void setVisible(boolean newVisible) {
172: fieldVisible = newVisible;
173: }
174: }
|