|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.shale.clay.convert.StringArrayConverter
public class StringArrayConverter
Converts a String
to a String[]
or
vise versa. This converter is targeted at supporting the
myfaces trinidad partialTriggers component properties.
The default element delimiter
is none and the default
element separator
is a space.
Constructor Summary | |
---|---|
StringArrayConverter()
|
Method Summary | |
---|---|
Object |
getAsObject(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent component,
String value)
Converts the value into a string array using
the element delimiter and element separator . |
String |
getAsString(javax.faces.context.FacesContext facesContext,
javax.faces.component.UIComponent component,
Object value)
Converts a string array into a value delimited string. |
Character |
getDelimiter()
|
Character |
getSeparator()
|
void |
setDelimiter(Character delimiter)
|
void |
setSeparator(Character separator)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StringArrayConverter()
Method Detail |
---|
public Character getDelimiter()
public void setDelimiter(Character delimiter)
delimiter
- element begining and ending delimiter charpublic Character getSeparator()
public void setSeparator(Character separator)
separator
- the character used to delimit elementspublic Object getAsObject(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent component, String value)
Converts the value
into a string array using
the element delimiter
and element separator
.
getAsObject
in interface javax.faces.convert.Converter
facesContext
- faces contextcomponent
- value holder componentvalue
- source value to converter to a String[]
String[]
public String getAsString(javax.faces.context.FacesContext facesContext, javax.faces.component.UIComponent component, Object value)
Converts a string array into a value delimited string. The delimiter
and separator
properties are used to distinguish each element.
getAsString
in interface javax.faces.convert.Converter
facesContext
- faces contextcomponent
- value owning componentvalue
- source String array that is converter into a tokenized String
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |