org.springframework.binding.value.support
Class DeepCopyBufferedCollectionValueModel
java.lang.Object
org.springframework.binding.value.support.AbstractPropertyChangePublisher
org.springframework.binding.value.support.AbstractValueModel
org.springframework.binding.value.support.BufferedValueModel
org.springframework.binding.value.support.BufferedCollectionValueModel
org.springframework.binding.value.support.DeepCopyBufferedCollectionValueModel
- All Implemented Interfaces:
- PropertyChangePublisher, ValueModelWrapper, ValueModel
public class DeepCopyBufferedCollectionValueModel
- extends BufferedCollectionValueModel
Implementation of a BufferedCollectionValueModel that performs a deep copy on the
elements of the collection.
- Author:
- Larry Streepy
Methods inherited from class org.springframework.binding.value.support.AbstractValueModel |
addValueChangeListener, fireValueChange, fireValueChange, fireValueChange, fireValueChange, fireValueChange, fireValueChangeEvent, fireValueChangeWhenStillEqual, getValueChangeDetector, removeValueChangeListener, setValueChangeDetector, setValueSilently |
Methods inherited from class org.springframework.binding.value.support.AbstractPropertyChangePublisher |
addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, firePropertiesChanged, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, getPropertyChangeListeners, getPropertyChangeListeners, getVetoableChangeListeners, getVetoableChangeListeners, hasChanged, hasChanged, hasChanged, hasChanged, hasChanged, hasChanged, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener |
DeepCopyBufferedCollectionValueModel
public DeepCopyBufferedCollectionValueModel(ValueModel wrappedModel,
Class wrappedType)
- Constructs a new DeepCopyBufferedCollectionValueModel.
- Parameters:
wrappedModel
- the value model to wrapwrappedType
- the class of the value contained by wrappedModel; this must be
assignable to java.util.Collection
or
Object[]
.
prepareBackingCollection
protected Collection prepareBackingCollection(Collection col)
- Prepare the backing collection for installation into the listListModel. Create a
new collection that contains a deep copy of the elements in the given collection.
- Overrides:
prepareBackingCollection
in class BufferedCollectionValueModel
- Parameters:
col
- The collection of objects to process
- Returns:
- processed collection
deepCopy
protected Object deepCopy(Object value)
- Create a new object that is a deep copy of the given object. This copy is created
using serialization, so the object to be copied must implement Serializable. If it
does not, then the original object will be returned. Any other error results in
null being returned.
- Parameters:
value
-
- Returns:
- deep copy
Copyright © 2004-2008 The Spring Framework. All Rights Reserved.