1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Cosmetics.

This commit is contained in:
Sergey Prigogin 2013-04-02 14:32:17 -07:00
parent 6ba8df52b2
commit 051c64bc24

View file

@ -6,7 +6,7 @@
* http://www.eclipse.org/legal/epl-v10.html * http://www.eclipse.org/legal/epl-v10.html
* *
* Contributors: * Contributors:
* Sergey Prigogin (Google) - initial API and implementation * Sergey Prigogin (Google) - initial API and implementation
*******************************************************************************/ *******************************************************************************/
package org.eclipse.cdt.internal.core.pdom; package org.eclipse.cdt.internal.core.pdom;
@ -21,8 +21,8 @@ public class AtomicMultiSet<T> {
private final HashMap<T, Integer> map = new HashMap<T, Integer>(); private final HashMap<T, Integer> map = new HashMap<T, Integer>();
/** /**
* Adds object to the set if it was not present, or increments its reference count * Adds object to the set if it was not present, or increments its reference count otherwise.
* otherwise. *
* @param object The object to add to the set. * @param object The object to add to the set.
* @return Reference count of the object after the operation. * @return Reference count of the object after the operation.
*/ */
@ -38,11 +38,12 @@ public class AtomicMultiSet<T> {
} }
/** /**
* Decrements reference count of the object in the set and removes the object if its * Decrements reference count of the object in the set and removes the object if its reference
* reference count reaches zero. * count reaches zero.
*
* @param object The object to remove from the set. * @param object The object to remove from the set.
* @return Reference count of the object after the operation, or -1 if the object was not * @return Reference count of the object after the operation, or -1 if the object was not
* present in the set. * present in the set.
*/ */
public synchronized int remove(T object) { public synchronized int remove(T object) {
Integer count = map.remove(object); Integer count = map.remove(object);