class AOStorageBuilder extends StorageBuilder {

    private static final HashMap<String, AOStorage> cache = new HashMap<>();

    public AOStorageBuilder() {
        this(null);
    }

    public AOStorageBuilder(Map<String, String> defaultConfig) {
        if (defaultConfig != null)
            config.putAll(defaultConfig);
    }

    @Override
    public AOStorage openStorage() {<FILL_FUNCTION_BODY>}

    private SchedulerFactory getSchedulerFactory() {
        SchedulerFactory sf = (SchedulerFactory) config.get(StorageSetting.SCHEDULER_FACTORY.name());
        if (sf == null) {
            sf = SchedulerFactory.getDefaultSchedulerFactory();
            if (sf == null) {
                CaseInsensitiveMap<String> config = new CaseInsensitiveMap<>(this.config.size());
                for (Map.Entry<String, Object> e : this.config.entrySet()) {
                    config.put(e.getKey(), e.getValue().toString());
                }
                sf = SchedulerFactory.initDefaultSchedulerFactory(EmbeddedScheduler.class.getName(),
                        config);
            }
        }
        if (!sf.isStarted())
            sf.start();
        return sf;
    }
}

        String storagePath = (String) config.get(StorageSetting.STORAGE_PATH.name());
        if (!config.containsKey(StorageSetting.IN_MEMORY.name()))
            DataUtils.checkNotNull(storagePath, "storage path");
        AOStorage storage = cache.get(storagePath);
        if (storage == null) {
            synchronized (cache) {
                storage = cache.get(storagePath);
                if (storage == null) {
                    storage = new AOStorage(config);
                    SchedulerFactory sf = getSchedulerFactory();
                    storage.setSchedulerFactory(sf);
                    cache.put(storagePath, storage);
                }
            }
        }
        return storage;
    
<methods>public non-sealed void <init>() ,public com.lealone.storage.StorageBuilder cacheSize(int) ,public com.lealone.storage.StorageBuilder compress() ,public com.lealone.storage.StorageBuilder compressHigh() ,public com.lealone.storage.StorageBuilder encryptionKey(char[]) ,public com.lealone.storage.StorageBuilder inMemory() ,public com.lealone.storage.StorageBuilder minFillRate(int) ,public abstract com.lealone.storage.Storage openStorage() ,public com.lealone.storage.StorageBuilder pageSize(int) ,public com.lealone.storage.StorageBuilder readOnly() ,public com.lealone.storage.StorageBuilder schedulerFactory(com.lealone.db.scheduler.SchedulerFactory) ,public com.lealone.storage.StorageBuilder storagePath(java.lang.String) ,public java.lang.String toString() <variables>protected final HashMap<java.lang.String,java.lang.Object> config