public static void resetCaches(int size) {
        nodesCache = new LinkedHashMap<String, List<Node>>() {
            @Override
            protected boolean removeEldestEntry(Map.Entry<String, List<Node>> foo) {
                return size() == size;
            }
        };

        vmsCache = new LinkedHashMap<String, List<VM>>() {
            @Override
            protected boolean removeEldestEntry(Map.Entry<String, List<VM>> foo) {
                return size() == size;
            }
        };
    }
public static void resetCaches ( int size ) { nodesCache = new LinkedHashMap < String , List < Node > > ( ) { @ Override protected boolean removeEldestEntry ( Map . Entry < String , List < Node > > foo ) { return size ( ) == size ; } } ; vmsCache = new LinkedHashMap < String , List < VM > > ( ) { @ Override protected boolean removeEldestEntry ( Map . Entry < String , List < VM > > foo ) { return size ( ) == size ; } } ; }
Reset the cache of element sets.

@param size the new cache size