1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.apache.jetspeed.services.search;
17
18 import java.util.Map;
19 import java.net.URL;
20
21 import org.apache.commons.collections.MultiMap;
22
23 /***
24 * Base parsed object.
25 *
26 * @author <a href="mailto:morciuch@apache.org">Mark Orciuch</a>
27 * @version $Id: BaseParsedObject.java,v 1.4 2004/02/23 03:48:47 jford Exp $
28 */
29 public class BaseParsedObject implements ParsedObject
30 {
31
32 private String key;
33 private String type;
34 private String title;
35 private String description;
36 private String content;
37 private String language;
38 private URL url;
39 private String[] keywords;
40 private MultiMap multiKeywords;
41 private Map fields;
42 private MultiMap multiFields;
43 private float score;
44 private String className;
45
46 /***
47 * Returns parsed object key
48 *
49 * @return
50 */
51 public String getKey()
52 {
53 return this.key;
54 }
55
56 /***
57 * Sets parsed object key
58 *
59 * @param content
60 */
61 public void setKey(String key)
62 {
63 this.key = key;
64 }
65
66 /***
67 * Returns parsed object type
68 *
69 * @return
70 */
71 public String getType()
72 {
73 return this.type;
74 }
75
76 /***
77 * Sets parsed object type
78 *
79 * @param type
80 */
81 public void setType(String type)
82 {
83 this.type = type;
84 }
85
86 /***
87 * Returns parsed object content
88 *
89 * @return
90 */
91 public String getContent()
92 {
93 return this.content;
94 }
95
96 /***
97 * Sets parsed object content
98 *
99 * @param content
100 */
101 public void setContent(String content)
102 {
103 this.content = content;
104 }
105
106 /***
107 * Returns parsed object description
108 *
109 * @return
110 */
111 public String getDescription()
112 {
113 return this.description;
114 }
115
116 /***
117 * Sets parsed object description
118 *
119 * @param description
120 */
121 public void setDescription(String description)
122 {
123 this.description = description;
124 }
125
126 /***
127 * Returns parsed object keywords
128 *
129 * @return
130 */
131 public String[] getKeywords()
132 {
133 return this.keywords;
134 }
135
136 /***
137 * Sets parsed object keywords
138 *
139 * @param keywords
140 */
141 public void setKeywords(String[] keywords)
142 {
143 this.keywords = keywords;
144 }
145
146 /***
147 * Returns parsed object title
148 *
149 * @return
150 */
151 public String getTitle()
152 {
153 return this.title;
154 }
155
156 /***
157 * Sets parsed object title
158 *
159 * @param title
160 */
161 public void setTitle(String title)
162 {
163 this.title = title;
164 }
165
166 /***
167 * Returns parsed object language
168 *
169 * @return
170 */
171 public String getLanguage()
172 {
173 return this.language;
174 }
175
176 /***
177 * Sets parsed object language
178 *
179 * @param language
180 */
181 public void setLanguage(String language)
182 {
183 this.language = language;
184 }
185
186 /***
187 * Returns parsed object searchable fields
188 *
189 * @return
190 */
191 public Map getFields()
192 {
193 return this.fields;
194 }
195
196 /***
197 * Sets parsed object searchable fields
198 *
199 * @param fields
200 */
201 public void setFields(Map fields)
202 {
203 this.fields = fields;
204 }
205
206 /***
207 * Returns parsed object URL
208 *
209 * @return
210 */
211 public URL getURL()
212 {
213 return this.url;
214 }
215
216 /***
217 * Sets parsed object URL
218 *
219 * @param fields
220 */
221 public void setURL(URL url)
222 {
223 this.url = url;
224 }
225
226 /***
227 * Getter for property score.
228 *
229 * @return Value of property score.
230 */
231 public float getScore()
232 {
233 return this.score;
234 }
235
236 /***
237 * Setter for property score.
238 *
239 * @param score New value of property score.
240 */
241 public void setScore(float score)
242 {
243 this.score = score;
244 }
245
246 /***
247 * Getter for property className.
248 *
249 * @return Value of property className.
250 */
251 public String getClassName()
252 {
253 return className;
254 }
255
256 /***
257 * Setter for property className.
258 *
259 * @param score New value of property className.
260 */
261 public void setClassName(String className)
262 {
263 this.className = className;
264 }
265
266 /***
267 * @see org.apache.jetspeed.services.search.ParsedObject#getMultiFields()
268 */
269 public MultiMap getMultiFields()
270 {
271 return multiFields;
272 }
273
274 /***
275 * @see org.apache.jetspeed.services.search.ParsedObject#setMultiFields(org.apache.commons.collections.MultiMap)
276 */
277 public void setMultiFields(MultiMap multiFields)
278 {
279 this.multiFields = multiFields;
280
281 }
282
283 /***
284 * @see org.apache.jetspeed.services.search.ParsedObject#getMultiKeywords()
285 */
286 public MultiMap getMultiKeywords()
287 {
288 return multiKeywords;
289 }
290
291 /***
292 * @see org.apache.jetspeed.services.search.ParsedObject#setMultiKeywords(org.apache.commons.collections.MultiMap)
293 */
294 public void setMultiKeywords(MultiMap multiKeywords)
295 {
296 this.multiKeywords = multiKeywords;
297 }
298
299 }
300