Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package edu.uiuc.ncsa.myproxy.oa4mp.oauth2.storage;
 
 
 import java.util.Set;
A very specific cleanup for store that know about refresh tokens. This returns the set of RefreshTokens (all unique) rather than the set of primary keys, so any retention policy is applied to those instead.

Created by Jeff Gaynor
on 3/26/14 at 3:31 PM

public class RefreshCleanup<K, V> extends Cleanup<K, V> {
    public RefreshCleanup(RefreshTokenStore refreshTokenStoreMyLoggingFacade logger) {
        super(logger);
        this. = refreshTokenStore;
    }
    @Override
    public Set<K> getSortedKeys() {
        TreeSet targetList = new TreeSet<>();
        for (Object key : .keySet()) {
            OA2ServiceTransaction st2 = (OA2ServiceTransaction.get(key);
            targetList.add(st2.getRefreshToken());
        }
        return targetList;
    }
New to GrepCode? Check out our FAQ X