List of usage examples for org.springframework.cache.interceptor KeyGenerator interface-usage
From source file com.create.security.oauth2.provider.token.ApprovalKeyGenerator.java
public class ApprovalKeyGenerator implements KeyGenerator { @Override public Object generate(final Object target, final Method method, final Object... params) { return createApprovalKey((String) params[0], (String) params[1]); }
From source file org.hsweb.concureent.cache.SimpleKeyGenerator.java
/** * @author zhouhao * @TODO */ public class SimpleKeyGenerator implements KeyGenerator { @Override
From source file org.wallride.autoconfigure.CacheKeyGenerator.java
public class CacheKeyGenerator implements KeyGenerator { @Override public Object generate(Object target, Method method, Object... params) { return method.toString() + " [" + StringUtils.arrayToCommaDelimitedString(params) + "]"; }
From source file org.slc.sli.dashboard.util.UserCacheKeyGenerator.java
/**
* Generates a cache key using the user's security token, class/method name, and method parameters.
* The majority of the dashboard caches are user-specific, so we include the security token by default.
*
* @author dwu
*
From source file com.create.security.oauth2.provider.token.OAuth2AccessTokenKeyGenerator.java
/** * Spring cache {@link KeyGenerator} for {@link OAuth2AccessToken} */ public class OAuth2AccessTokenKeyGenerator implements KeyGenerator { @Override public Object generate(final Object target, final Method method, final Object... params) {
From source file com.create.security.oauth2.provider.token.OAuth2RefreshTokenKeyGenerator.java
/** * Spring cache {@link KeyGenerator} for {@link OAuth2RefreshToken} */ public class OAuth2RefreshTokenKeyGenerator implements KeyGenerator { @Override public Object generate(final Object target, final Method method, final Object... params) {
From source file nl.surfnet.coin.shared.cache.MethodNameAwareCacheKeyGenerator.java
/**
* {@link KeyGenerator} that also takes into account the methodName when
* generating keys. This appeared to be necessary in JanusClientDetailsService
* (see the #testCache method in the corresponding unit test class)
*
* Also added target.hashCode(), to differentiate between cacheable methods that have the same signature
From source file org.podcastpedia.web.caching.EnhancedDefaultKeyGenerator.java
/**
* Default key generator. Returns {@value #NO_PARAM_KEY} if no
* parameters are provided, the parameter itself if only one is given or
* a hash code computed from all given parameters' hash code values.
* Uses the constant value {@value #NULL_PARAM_KEY} for any
* {@code null} parameters given.
From source file com.create.security.oauth2.provider.token.OAuth2AuthenticationKeyGenerator.java
/** * Spring cache {@link KeyGenerator} for {@link OAuth2Authentication} */ public class OAuth2AuthenticationKeyGenerator implements KeyGenerator { private final AuthenticationKeyGenerator authenticationKeyGenerator;
From source file grails.plugin.cache.SimpleKeyGenerator.java
/**
* Copy of Spring 4.0's {@link org.springframework.cache.interceptor.SimpleKeyGenerator} and {@link org.springframework.cache.interceptor.SimpleKey}
*
* Simple key generator. Returns the parameter itself if a single non-null value
* is given, otherwise returns a {@link SimpleKey} of the parameters.
*