trimmingcache.java

来自「Java的面向对象数据库系统的源代码」· Java 代码 · 共 45 行

JAVA
45
字号
// You can redistribute this software and/or modify it under the terms of// the Ozone Core License version 1 published by ozone-db.org.//// Copyright (C) 2003-@year@, Leo Mekenkamp. All rights reserved.//// $Id: TrimmingCache.java,v 1.1.2.1 2004/03/28 16:40:04 per_nyfelt Exp $package org.ozoneDB.core.storage;/** * A trimming cache is a cache that calls a TrimHandler when it 'knows' that * it has thrown an element out of the cache. *  * @author <a href="mailto:leoATmekenkampD0Tcom">Leo Mekenkamp (mind the anti sp@m)</a> * @version $Id: TrimmingCache.java,v 1.1.2.1 2004/03/28 16:40:04 per_nyfelt Exp $ */public interface TrimmingCache extends Cache {        /**     * Used by a <code>Cache</code> to provide for a meganism to handle elements     * that are going to be thrown out of that cache.     */    public interface TrimHandler {                /**         * Called by a <code>TrimmingCache</code> just before an element will be         * removed from that cache.         * This method may be called asynchronously (by different threads)         * depending on the implementation.         */        public void trimming(Object key, Object value);            }        public void setTrimHandler(TrimHandler trimHandler);        public TrimHandler getTrimHandler();     public void setSynchronizer(Object synchronizer);    public Object getSynchronizer();}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?