|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.openadaptor.dostrings.transformers.AbstractTransformer
org.openadaptor.dostrings.transformers.TrimTransformer
public class TrimTransformer
A simple transformer which takes the string value of the object passed to it and trims off all leading and trailing whitespace. Can be used in Readers and Writers.
Constructor Summary | |
---|---|
TrimTransformer()
|
Method Summary | |
---|---|
void |
init(java.util.Properties props,
java.lang.String prefix)
Does nothing. |
java.lang.Object |
transform(java.lang.Object o)
Returns trimmed string value. |
Methods inherited from class org.openadaptor.dostrings.transformers.AbstractTransformer |
---|
getBooleanProperty, getProperty, getPropertyDefs, init |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TrimTransformer()
Method Detail |
---|
public void init(java.util.Properties props, java.lang.String prefix) throws DOStringException
init
in interface ObjectTransformer
init
in class AbstractTransformer
props
- Properties object containing our properties.prefix
- Our properties prefix.
DOStringException
- If mandatory properties are not defined, or any
property is incorrectly defined.public java.lang.Object transform(java.lang.Object o) throws DOStringException
o
- Object whose string value is to be trimmed.
DOStringException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |