Code example for CopyOnWriteArrayList

Methods: add, contains

0
        super(source);
        // TODO Auto-generated constructor stub 
    } 
 
    public void addPropertyChangeListener(final PropertyChangeListener<T> listener) {
        if (!this.listeners.contains(listener)) {
            this.listeners.add(listener);
        } 
    } 
 
    @Override 
    public void addPropertyChangeListener(final java.beans.PropertyChangeListener listener) {
        if (!this.listeners.contains(listener)) {
            this.listeners.add(listener);
        } 
    } 
 
    @Override 
    public String getAsText() {
        return (this.value != null) ? this.value.toString() : null;
    }