Example usage for org.apache.commons.collections.map LRUMap clear

List of usage examples for org.apache.commons.collections.map LRUMap clear

Introduction

In this page you can find the example usage for org.apache.commons.collections.map LRUMap clear.

Prototype

public void clear() 

Source Link

Document

Clears the map, resetting the size to zero and nullifying references to avoid garbage collection issues.

Usage

From source file:de.suse.swamp.core.api.WorkflowAPI.java

public void doEmptywfcache(String uname) throws StorageException, SecurityException, UnknownElementException {
    if (!SecurityManager.isGroupMember(SecurityManager.getUser(uname), "swampadmins")) {
        throw new SecurityException("Not allowed to truncate Caches.");
    }/*from  w  ww  . j  a v a2 s . c o  m*/
    WorkflowManager wfm = WorkflowManager.getInstance();
    LRUMap cache = wfm.getWorkflowCache();
    cache.clear();
}