Examples of LRUMap


Examples of org.apache.commons.collections.map.LRUMap

     *                  registration.
     * @param cacheSize number of mappings this resolver may cache.
     */
    public CachingNamespaceResolver(AbstractNamespaceResolver base, int cacheSize) {
        this.base = base;
        qnameToJCRName = new LRUMap(cacheSize);
        jcrNameToQName = new LRUMap(cacheSize);
        this.base.addListener(this);
    }
View Full Code Here

Examples of org.apache.commons.collections.map.LRUMap

     */
    @SuppressWarnings("unchecked")   
    CachingEntryCollector(SessionImpl systemSession, NodeId rootID) throws RepositoryException {
        super(systemSession, rootID);
       
        cache = new LRUMap(1000);
    }
View Full Code Here

Examples of org.apache.commons.collections.map.LRUMap

        if (initialized) {
            throw new IllegalStateException("already initialized");
        }

        int maxSize = Integer.parseInt(options.getProperty(MAXSIZE_KEY, "1000"));
        cache = new LRUMap(maxSize);
        includeNegative = Boolean.parseBoolean(options.getProperty(NEGATIVE_ENTRY_KEY, "false"));
       
        initialized = true;
    }
View Full Code Here

Examples of org.apache.commons.collections.map.LRUMap

        this.systemSession = systemSession;
        this.systemEditor = systemEditor;

        repPolicyName = systemSession.getJCRName(N_POLICY);

        cache = new LRUMap(1000);

        ObservationManager observationMgr = systemSession.getWorkspace().getObservationManager();
        /*
         Make sure the collector and all subscribed listeners are informed upon
         ACL modifications. Interesting events are:
View Full Code Here

Examples of org.apache.commons.collections.map.LRUMap

        if (initCache) {
            cacheInitializer.run();
        }
        // limit cache to 1% of maxDoc(), but at least 10.
        this.docNumber2id = Collections.synchronizedMap(
                new LRUMap(Math.max(10, delegatee.maxDoc() / 100)));
        this.termDocsCache = new TermDocsCache(delegatee, FieldNames.PROPERTIES);
    }
View Full Code Here

Examples of org.apache.commons.collections.map.LRUMap

        this.systemSession = systemSession;
        this.groupsPath = (groupsPath == null) ? UserConstants.GROUPS_PATH : groupsPath;
        this.useMembersNode = useMembersNode;

        pMembers = systemSession.getJCRName(UserManagerImpl.P_MEMBERS);
        cache = new LRUMap();
               
        String[] ntNames = new String[] {
                systemSession.getJCRName(UserConstants.NT_REP_GROUP),
                systemSession.getJCRName(UserConstants.NT_REP_MEMBERS)
        };
View Full Code Here

Examples of org.apache.commons.collections.map.LRUMap

     * @see AbstractAuthenticator
     */
    public SimpleAuthenticator()
    {
        super( AuthenticationLevel.SIMPLE.toString() );
        credentialCache = new LRUMap( DEFAULT_CACHE_SIZE );
    }
View Full Code Here

Examples of org.apache.commons.collections.map.LRUMap

     */
    public SimpleAuthenticator( int cacheSize )
    {
        super( AuthenticationLevel.SIMPLE.toString() );

        credentialCache = new LRUMap( cacheSize > 0 ? cacheSize : DEFAULT_CACHE_SIZE );
    }
View Full Code Here

Examples of org.apache.commons.collections.map.LRUMap

        // init ivars from properties
        this.notifyingRemoteListeners = notifyRemote;

        // TODO: ENTRY EXPIRATION is not supported by commons LRU Map
        this.snapshots = new LRUMap(snapshotsCacheSize);

        // init event bridge only if we are notifying remote listeners
        if (notifyingRemoteListeners) {
            try {
                EventBridgeFactory factory = (EventBridgeFactory) Class.forName(
View Full Code Here

Examples of org.apache.commons.collections.map.LRUMap

        this.dirContext = dirContext;
        if (dirContext instanceof BaseDirContext) {
            // Initialize parameters based on the associated dir context, like
            // the caching policy.
            if (((BaseDirContext) dirContext).isCached()) {
                cache = Collections.synchronizedMap(new LRUMap(cacheSize));
                cacheTTL = ((BaseDirContext) dirContext).getCacheTTL();
                cacheObjectMaxSize =
                    ((BaseDirContext) dirContext).getCacheObjectMaxSize();
            }
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.