package org.jfox.pool;

/**
 * @author <a href="mailto:yangyong@ufsoft.com.cn">Young Yang</a>
 */

public class IndexablePoolTest {

    public static void main(String[] args) throws Exception {
        AbstractIndexableObjectPool pool = new SimpleIndexableObjectPool(new SimpleObjectFactory(TestPoolableObject.class));
        pool.init();
        TestPoolableObject obj = (TestPoolableObject) pool.retrieveObject("Test");
        System.out.println("from PoolableObject: " + obj.say());
        pool.restoreObject("Test", obj);
        pool.removeObject("Test");
    }
}

