mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Jean-Noel Rouvignac
16.30.2014 13d1b7c788ad8f598589fc5e2116e114831ec9e8
AutoRefactored for the use of Collection.addAll().
3 files modified
17 ■■■■ changed files
opendj-config/src/main/java/org/forgerock/opendj/config/dsconfig/PropertyValueEditor.java 9 ●●●●● patch | view | raw | blame | history
opendj-core/src/main/java/org/forgerock/opendj/ldap/AbstractAttribute.java 4 ●●● patch | view | raw | blame | history
opendj-server/src/main/java/org/forgerock/opendj/server/core/DataProviderEvent.java 4 ●●● patch | view | raw | blame | history
opendj-config/src/main/java/org/forgerock/opendj/config/dsconfig/PropertyValueEditor.java
@@ -2073,20 +2073,17 @@
                registerSetModification(pd, newValues, previousValues);
            } else {
                // Split into two operations: remove and add
                SortedSet<T> removedValues = new TreeSet<T>();
                removedValues.addAll(previousValues);
                SortedSet<T> removedValues = new TreeSet<T>(previousValues);
                removedValues.removeAll(newValues);
                PropertyEditorModification<T> removeMod = PropertyEditorModification.createRemoveModification(pd,
                        removedValues, previousValues);
                addModification(removeMod);
                SortedSet<T> retainedValues = new TreeSet<T>();
                retainedValues.addAll(previousValues);
                SortedSet<T> retainedValues = new TreeSet<T>(previousValues);
                retainedValues.retainAll(newValues);
                SortedSet<T> addedValues = new TreeSet<T>();
                addedValues.addAll(newValues);
                SortedSet<T> addedValues = new TreeSet<T>(newValues);
                addedValues.removeAll(retainedValues);
                PropertyEditorModification<T> addMod = PropertyEditorModification.createAddModification(pd,
opendj-core/src/main/java/org/forgerock/opendj/ldap/AbstractAttribute.java
@@ -287,9 +287,7 @@
        if (isEmpty()) {
            if (missingValues != null) {
                for (final T value : values) {
                    missingValues.add(value);
                }
                missingValues.addAll(values);
            }
            return false;
        }
opendj-server/src/main/java/org/forgerock/opendj/server/core/DataProviderEvent.java
@@ -89,9 +89,7 @@
        this.reason = reason;
        final EnumSet<Type> tmp = EnumSet.noneOf(Type.class);
        for (final Type type : types) {
            tmp.add(type);
        }
        tmp.addAll(types);
        this.types = Collections.unmodifiableSet(tmp);
    }