public void setWrappedData(Object data) {
        if (data == null) {
            inner = null;
            arrayFromInner = null;
            setRowIndex(-1);
        } else {
            inner = (Collection<E>) data;            
            arrayFromInner = (E[]) new Object[inner.size()];
            inner.toArray(arrayFromInner);
            setRowIndex(0);
        }
    }
public void setWrappedData ( Object data ) { if ( data == null ) { inner = null ; arrayFromInner = null ; setRowIndex ( - 1 ) ; } else { inner = ( Collection < E > ) data ; arrayFromInner = ( E [ ] ) new Object [ inner . size ( ) ] ; inner . toArray ( arrayFromInner ) ; setRowIndex ( 0 ) ; } }
Set the wrapped data.

@param data the wrapped data.
@throws ClassCastException if <code>data</code> is
non-<code>null</code> and is not a <code>Collection</code>