public static class JCacheConfiguration.Builder extends Object implements ConfigurationSectionBuilder<JCacheConfiguration>
| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
JCacheConfiguration |
buildConfigurationSection() |
JCacheConfiguration.Builder |
copyAlwaysIfRequested(boolean f)
When
true, copy keys and values when entering and leaving
the cache in case Configuration.isStoreByValue()
is true. |
JCacheConfiguration.Builder |
enableManagement(boolean f)
When
true makes the JMX management bean for the cache available. |
JCacheConfiguration.Builder |
enableReadThrough(boolean f)
When
true, operate cache in read through mode and use the configured
loader when there is no mapping for a key yet. |
JCacheConfiguration.Builder |
enableStatistics(boolean f)
When
true, exposes cache statistics via JMX. |
JCacheConfiguration.Builder |
supportOnlineListenerAttachment(boolean f)
Set to true, if online register and deregister of event listeners needs to be supported.
|
public JCacheConfiguration.Builder copyAlwaysIfRequested(boolean f)
true, copy keys and values when entering and leaving
the cache in case Configuration.isStoreByValue()
is true.
This needs to be enabled for 100% JCache compatibility.
Default, if no cache2k configuration is present: true.
Default in cache2k configuration mode: false.public JCacheConfiguration.Builder supportOnlineListenerAttachment(boolean f)
true.
Default in cache2k configuration mode: false.Cache.registerCacheEntryListener(CacheEntryListenerConfiguration)public JCacheConfiguration.Builder enableManagement(boolean f)
true makes the JMX management bean for the cache available.
Identical to the flag in the JCache configuration object.CompleteConfiguration.isManagementEnabled()public JCacheConfiguration.Builder enableStatistics(boolean f)
true, exposes cache statistics via JMX. Identical to the flag
in the JCache configuration object.CompleteConfiguration.isManagementEnabled()public JCacheConfiguration.Builder enableReadThrough(boolean f)
true, operate cache in read through mode and use the configured
loader when there is no mapping for a key yet. Identical to the flag in the JCache
configuration object.CompleteConfiguration.isReadThrough()public JCacheConfiguration buildConfigurationSection()
buildConfigurationSection in interface ConfigurationSectionBuilder<JCacheConfiguration>cache2k API documentation. Copyright © 2000–2019 headissue GmbH, Munich.