|
From: Rob M. <Rob...@pe...> - 2004-06-09 23:16:51
|
jürgen höller [werk3AT] wrote:
> Actually, Spring does provide a default StringArrayPropertyEditor that separates CSV into multiple String values, being able to convert the individual values then. So you should be able to register an editor for Long, driving it with a CSV String.
>
> Registering for an array itself is straightforward:
>
> binder.registerCustomEditor(Boolean[].class, new PropertyEditorSupport() {
> public void setAsText(String text) {
> Boolean[] array = new Boolean[];
> ...
> setValue(array);
> }
> });
>
Ah, okay. I didn't realize you could declare an array class reference
like that. Thanks for the nudge -- it worked like a charm.
Muchas gracias,
Rob
|