01: /*
02: * Created on Feb 6, 2004
03: *
04: * To change the template for this generated file go to
05: * Window>Preferences>Java>Code Generation>Code and Comments
06: */
07: package org.xdev.base.xssl.text;
08:
09: import java.util.HashMap;
10: import java.util.StringTokenizer;
11:
12: /**
13: * @author AYegorov
14: *
15: * To change the template for this generated type comment go to
16: * Window>Preferences>Java>Code Generation>Code and Comments
17: */
18: public class TextTokens extends AbstractText {
19: /**
20: * @param id
21: */
22: public TextTokens(String id) {
23: super (id);
24: // XXX Auto-generated constructor stub
25: }
26:
27: /**
28: * @param id
29: * @param properties
30: */
31: public TextTokens(String id, HashMap properties) {
32: super (id, properties);
33: // XXX Auto-generated constructor stub
34: }
35:
36: /* (non-Javadoc)
37: * @see org.xdev.base.xssl.text.AbstractText#processText(java.lang.String)
38: */
39: protected Object processText(String text) throws Exception {
40: return text != null ? text
41: .split(this .getProperty("expression"))
42: : new String[] {};
43: }
44: }
|