Class GCacheFactory
- java.lang.Object
-
- com.google.appengine.api.memcache.stdimpl.GCacheFactory
-
- All Implemented Interfaces:
javax.cache.CacheFactory
public class GCacheFactory extends Object implements javax.cache.CacheFactory
JCache CacheFactory implementation using Memcache.
-
-
Field Summary
Fields Modifier and Type Field Description static intEXPIRATIONProperty key for absolute expiration time for all put operations as aDate.static intEXPIRATION_DELTAProperty key for expiration time in seconds set for all put operations as an Integer.static intEXPIRATION_DELTA_MILLISProperty key for expiration time in milliseconds set for all put operations as an Integer.static intMEMCACHE_SERVICEProperty key for memcache service to use as aMemcacheService.static intNAMESPACEProperty key for defining a non-default namespace.static intSET_POLICYProperty key for put operation policy as aMemcacheService.SetPolicy.
-
Constructor Summary
Constructors Constructor Description GCacheFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.cache.CachecreateCache(Map map)Creates a cache instance using the memcache service.
-
-
-
Field Detail
-
EXPIRATION_DELTA
public static final int EXPIRATION_DELTA
Property key for expiration time in seconds set for all put operations as an Integer.- See Also:
- Constant Field Values
-
EXPIRATION_DELTA_MILLIS
public static final int EXPIRATION_DELTA_MILLIS
Property key for expiration time in milliseconds set for all put operations as an Integer.- See Also:
- Constant Field Values
-
EXPIRATION
public static final int EXPIRATION
Property key for absolute expiration time for all put operations as aDate.- See Also:
- Constant Field Values
-
SET_POLICY
public static final int SET_POLICY
Property key for put operation policy as aMemcacheService.SetPolicy. Defaults toSetPolicy.SET_ALWAYSif not specified.- See Also:
- Constant Field Values
-
MEMCACHE_SERVICE
public static final int MEMCACHE_SERVICE
Property key for memcache service to use as aMemcacheService. Defaults to that provided byMemcacheServiceFactory.getMemcacheServiceif not specified.- See Also:
- Constant Field Values
-
NAMESPACE
public static final int NAMESPACE
Property key for defining a non-default namespace. This has the same effect setting a namespace usingMemcacheServiceFactory.getMemcacheService(String). This property is ignored if MEMCACHE_SERVICE property specified.- See Also:
- Constant Field Values
-
-
Method Detail
-
createCache
public javax.cache.Cache createCache(Map map)
Creates a cache instance using the memcache service.- Specified by:
createCachein interfacejavax.cache.CacheFactory- Parameters:
map- A map of properties.- Returns:
- a cache.
-
-