com.maxifier.mxcache.guava.GuavaOption Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of mxcache-guava-integration Show documentation
Show all versions of mxcache-guava-integration Show documentation
A set of custom caching strategies for Google Guava library
/*
* Copyright (c) 2008-2014 Maxifier Ltd. All Rights Reserved.
*/
package com.maxifier.mxcache.guava;
import com.google.common.cache.CacheBuilder;
/**
* GuavaOption
*
* @author Alexander Kochurov ([email protected]) (2012-10-09 09:34)
*/
public enum GuavaOption {
SOFT_VALUES {
@Override
public void set(CacheBuilder, ?> builder) {
builder.softValues();
}
}, WEAK_KEYS {
@Override
public void set(CacheBuilder, ?> builder) {
builder.weakKeys();
}
}, WEAK_VALUES {
@Override
public void set(CacheBuilder, ?> builder) {
builder.weakValues();
}
}, RECORD_STATS {
@Override
public void set(CacheBuilder, ?> builder) {
builder.recordStats();
}
};
public abstract void set(CacheBuilder, ?> builder);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy