copper-server-mongo/src/main/java/com/pogeyan/cmis/data/mongo/PassiveExpiringMap.java
/**
	 * Removes all entries in the map whose expiration time is less than
	 * {@code now}. The exceptions are entries with negative expiration times; those
	 * entries are never removed.
	 *
	 * @see #isExpired(long, Long)
	 */
Removes all entries in the map whose expiration time is less than
now. The exceptions are entries with negative expiration times; those
entries are never removed.


Removes all entries in the map whose expiration time is less than now . The exceptions are entries with negative expiration times ; those entries are never removed .
private void removeAllExpired(final long now) {
		final Iterator<Map.Entry<Object, Long>> iter = expirationMap.entrySet().iterator();
		while (iter.hasNext()) {
			final Map.Entry<Object, Long> expirationEntry = iter.next();
			if (isExpired(now, expirationEntry.getValue())) {
				if (listener != null) {
					listener.notifyOnRemoval(expirationEntry.getKey(), super.get(expirationEntry.getKey()));
				}
				super.remove(expirationEntry.getKey());
				iter.remove();
			}
		}
	}
private void removeAllExpired ( final long now ) { final Iterator < Map . Entry < Object , Long > > iter = expirationMap . entrySet ( ) . iterator ( ) ; while ( iter . hasNext ( ) ) { final Map . Entry < Object , Long > expirationEntry = iter . next ( ) ; if ( isExpired ( now , expirationEntry . getValue ( ) ) ) { if ( listener != null ) { listener . notifyOnRemoval ( expirationEntry . getKey ( ) , super . get ( expirationEntry . getKey ( ) ) ) ; } super . remove ( expirationEntry . getKey ( ) ) ; iter . remove ( ) ; } } }
Removes all entries in the map whose expiration time is less than
 {@code now}.
Removes all entries in the map whose expiration time is less than { @code now } .
// remove entry from collection // remove entry from expiration map