public class SettingCacheSelector extends Object implements org.exoplatform.services.cache.CachedObjectSelector<org.exoplatform.commons.api.settings.data.SettingKey,Object>
| Constructor and Description |
|---|
SettingCacheSelector(org.exoplatform.commons.api.settings.data.SettingContext provider)
Create a selector with a specified context
|
| Modifier and Type | Method and Description |
|---|---|
void |
onSelect(org.exoplatform.services.cache.ExoCache<? extends org.exoplatform.commons.api.settings.data.SettingKey,? extends Object> cache,
org.exoplatform.commons.api.settings.data.SettingKey key,
org.exoplatform.services.cache.ObjectCacheInfo<? extends Object> ocinfo)
Callback function if select function return true.
|
boolean |
select(org.exoplatform.commons.api.settings.data.SettingKey key,
org.exoplatform.services.cache.ObjectCacheInfo<? extends Object> ocinfo)
This function allows this selector could select right object.
|
public SettingCacheSelector(org.exoplatform.commons.api.settings.data.SettingContext provider)
provider - context or scope with which the specified value is to be associatedpublic boolean select(org.exoplatform.commons.api.settings.data.SettingKey key,
org.exoplatform.services.cache.ObjectCacheInfo<? extends Object> ocinfo)
select in interface org.exoplatform.services.cache.CachedObjectSelector<org.exoplatform.commons.api.settings.data.SettingKey,Object>key - the key which is composed by context, scope, keyocinfo - cache info (expire time, cache associated object)public void onSelect(org.exoplatform.services.cache.ExoCache<? extends org.exoplatform.commons.api.settings.data.SettingKey,? extends Object> cache, org.exoplatform.commons.api.settings.data.SettingKey key, org.exoplatform.services.cache.ObjectCacheInfo<? extends Object> ocinfo) throws Exception
Copyright © 2003–2016 eXo Platform SAS. All rights reserved.