Package org.jboss.common.beans.property
Class StringArrayEditor
- java.lang.Object
-
- java.beans.PropertyEditorSupport
-
- org.jboss.common.beans.property.PropertyEditorSupport<T>
-
- org.jboss.common.beans.property.GenericArrayPropertyEditor<java.lang.String[]>
-
- org.jboss.common.beans.property.StringArrayEditor
-
- All Implemented Interfaces:
java.beans.PropertyEditor,PropertyEditor<java.lang.String[]>
public class StringArrayEditor extends GenericArrayPropertyEditor<java.lang.String[]>
A property editor for String[]. The text format of a string array is a comma or \n, \r seperated list with \, representing an escaped comma to include in the string element.
-
-
Constructor Summary
Constructors Constructor Description StringArrayEditor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.Stringencode(java.lang.String[] v)voidsetAsText(java.lang.String text)Set the property value by parsing a given String.protected java.lang.String[]tokenize(java.lang.String text)-
Methods inherited from class org.jboss.common.beans.property.GenericArrayPropertyEditor
getAsText, getCellType, getTokenizer
-
Methods inherited from class org.jboss.common.beans.property.PropertyEditorSupport
addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, getType, getValue, removePropertyChangeListener, removePropertyChangeListener, setValue
-
-
-
-
Method Detail
-
setAsText
public void setAsText(java.lang.String text) throws java.lang.IllegalArgumentExceptionDescription copied from interface:PropertyEditorSet the property value by parsing a given String. May raise java.lang.IllegalArgumentException if either the String is badly formatted or if this kind of property can't be expressed as text.- Specified by:
setAsTextin interfacejava.beans.PropertyEditor- Specified by:
setAsTextin interfacePropertyEditor<java.lang.String[]>- Overrides:
setAsTextin classGenericArrayPropertyEditor<java.lang.String[]>- Parameters:
text- The string to be parsed.- Throws:
java.lang.IllegalArgumentException
-
tokenize
protected java.lang.String[] tokenize(java.lang.String text)
- Overrides:
tokenizein classGenericArrayPropertyEditor<java.lang.String[]>
-
encode
protected java.lang.String encode(java.lang.String[] v)
- Overrides:
encodein classGenericArrayPropertyEditor<java.lang.String[]>
-
-