本文整理了Java中net.sf.ehcache.Ehcache.getInternalContext()
方法的一些代码示例,展示了Ehcache.getInternalContext()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Ehcache.getInternalContext()
方法的具体详情如下:
包路径:net.sf.ehcache.Ehcache
类名称:Ehcache
方法名:getInternalContext
[英]This should not be used
[中]这不应该被使用
代码示例来源:origin: net.sf.ehcache/ehcache
/**
* {@inheritDoc}
*/
public Object getInternalContext() {
return underlyingCache.getInternalContext();
}
代码示例来源:origin: net.sf.ehcache/ehcache
/**
* Creates a new Hibernate pluggable cache by name.
* <p>
* ehcache will look in ehcache.xml to load the configuration for the cache.
* If the cache is not there, it will use the defaultCache settings. It is
* always a good idea to specifically configure each cache.
*
* @param cache The backing ehcache cache.
*/
public EhCache(net.sf.ehcache.Ehcache cache) {
this.cache = cache;
Object context = cache.getInternalContext();
if (context instanceof CacheLockProvider) {
lockProvider = (CacheLockProvider) context;
} else {
lockProvider = null;
}
}
代码示例来源:origin: net.sf.ehcache/ehcache
/**
* {@inheritDoc}
*/
public Object getInternalContext() {
// THIS IS GENERATED CODE -- DO NOT HAND MODIFY!
Thread t = Thread.currentThread();
ClassLoader prev = t.getContextClassLoader();
t.setContextClassLoader(this.classLoader);
try {
return this.cache.getInternalContext();
} finally {
t.setContextClassLoader(prev);
}
}
代码示例来源:origin: net.sf.ehcache/ehcache
/**
* Construct an transactional Hibernate cache region around the given Ehcache instance.
*/
EhcacheTransactionalDataRegion(EhcacheAccessStrategyFactory accessStrategyFactory, Ehcache cache, Settings settings,
CacheDataDescription metadata, Properties properties) {
super(accessStrategyFactory, cache, properties);
this.settings = settings;
this.metadata = metadata;
Object context = cache.getInternalContext();
if (context instanceof CacheLockProvider) {
this.lockProvider = (CacheLockProvider) context;
} else {
this.lockProvider = new StripedReadWriteLockSync(LOCAL_LOCK_PROVIDER_CONCURRENCY);
}
}
代码示例来源:origin: net.sf.ehcache/ehcache
private CacheLockProvider createCacheLockProvider() {
Object context = underlyingCache.getInternalContext();
if (underlyingCache.getCacheConfiguration().isTerracottaClustered() && context != null) {
return (CacheLockProvider) context;
} else {
return new StripedReadWriteLockSync(stripes);
}
}
代码示例来源:origin: net.sf.ehcache.internal/ehcache-core
/**
* {@inheritDoc}
*/
public Object getInternalContext() {
return underlyingCache.getInternalContext();
}
代码示例来源:origin: org.sonatype.nexus.bundles/org.sonatype.nexus.bundles.ehcache
/**
* {@inheritDoc}
*/
public Object getInternalContext() {
return underlyingCache.getInternalContext();
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.ehcache
/**
* {@inheritDoc}
*/
public Object getInternalContext() {
return underlyingCache.getInternalContext();
}
代码示例来源:origin: net.sf.ehcache/ehcache-explicitlocking
/**
* {@inheritDoc}
*/
public Object getInternalContext() {
return cache.getInternalContext();
}
代码示例来源:origin: com.madgag/mini-git-server-server
public Object getInternalContext() {
return self.getInternalContext();
}
代码示例来源:origin: rtyley/mini-git-server
public Object getInternalContext() {
return self.getInternalContext();
}
代码示例来源:origin: org.sonatype.nexus.bundles/org.sonatype.nexus.bundles.ehcache
/**
* {@inheritDoc}
*/
public Object getInternalContext() {
// THIS IS GENERATED CODE -- DO NOT HAND MODIFY!
Thread t = Thread.currentThread();
ClassLoader prev = t.getContextClassLoader();
t.setContextClassLoader(this.classLoader);
try {
return this.cache.getInternalContext();
} finally {
t.setContextClassLoader(prev);
}
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.ehcache
/**
* {@inheritDoc}
*/
public Object getInternalContext() {
// THIS IS GENERATED CODE -- DO NOT HAND MODIFY!
Thread t = Thread.currentThread();
ClassLoader prev = t.getContextClassLoader();
t.setContextClassLoader(this.classLoader);
try {
return this.cache.getInternalContext();
} finally {
t.setContextClassLoader(prev);
}
}
代码示例来源:origin: net.sf.ehcache.internal/ehcache-core
/**
* {@inheritDoc}
*/
public Object getInternalContext() {
// THIS IS GENERATED CODE -- DO NOT HAND MODIFY!
Thread t = Thread.currentThread();
ClassLoader prev = t.getContextClassLoader();
t.setContextClassLoader(this.classLoader);
try {
return this.cache.getInternalContext();
} finally {
t.setContextClassLoader(prev);
}
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.ehcache
/**
* Construct an transactional Hibernate cache region around the given Ehcache instance.
*/
EhcacheTransactionalDataRegion(EhcacheAccessStrategyFactory accessStrategyFactory, Ehcache cache, Settings settings,
CacheDataDescription metadata, Properties properties) {
super(accessStrategyFactory, cache, properties);
this.settings = settings;
this.metadata = metadata;
Object context = cache.getInternalContext();
if (context instanceof CacheLockProvider) {
this.lockProvider = (CacheLockProvider) context;
} else {
this.lockProvider = new StripedReadWriteLockSync(LOCAL_LOCK_PROVIDER_CONCURRENCY);
}
}
代码示例来源:origin: net.sf.ehcache.internal/ehcache-core
/**
* Construct an transactional Hibernate cache region around the given Ehcache instance.
*/
EhcacheTransactionalDataRegion(EhcacheAccessStrategyFactory accessStrategyFactory, Ehcache cache, Settings settings,
CacheDataDescription metadata, Properties properties) {
super(accessStrategyFactory, cache, properties);
this.settings = settings;
this.metadata = metadata;
Object context = cache.getInternalContext();
if (context instanceof CacheLockProvider) {
this.lockProvider = (CacheLockProvider) context;
} else {
this.lockProvider = new StripedReadWriteLockSync(LOCAL_LOCK_PROVIDER_CONCURRENCY);
}
}
代码示例来源:origin: org.sonatype.nexus.bundles/org.sonatype.nexus.bundles.ehcache
/**
* Construct an transactional Hibernate cache region around the given Ehcache instance.
*/
EhcacheTransactionalDataRegion(EhcacheAccessStrategyFactory accessStrategyFactory, Ehcache cache, Settings settings,
CacheDataDescription metadata, Properties properties) {
super(accessStrategyFactory, cache, properties);
this.settings = settings;
this.metadata = metadata;
Object context = cache.getInternalContext();
if (context instanceof CacheLockProvider) {
this.lockProvider = (CacheLockProvider) context;
} else {
this.lockProvider = new StripedReadWriteLockSync(LOCAL_LOCK_PROVIDER_CONCURRENCY);
}
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.ehcache
private CacheLockProvider createCacheLockProvider() {
Object context = underlyingCache.getInternalContext();
if (underlyingCache.getCacheConfiguration().isTerracottaClustered() && context != null) {
return (CacheLockProvider) context;
} else {
return new StripedReadWriteLockSync(stripes);
}
}
代码示例来源:origin: org.sonatype.nexus.bundles/org.sonatype.nexus.bundles.ehcache
private CacheLockProvider createCacheLockProvider() {
Object context = underlyingCache.getInternalContext();
if (underlyingCache.getCacheConfiguration().isTerracottaClustered() && context != null) {
return (CacheLockProvider) context;
} else {
return new StripedReadWriteLockSync(stripes);
}
}
代码示例来源:origin: net.sf.ehcache.internal/ehcache-core
private CacheLockProvider createCacheLockProvider() {
Object context = underlyingCache.getInternalContext();
if (underlyingCache.getCacheConfiguration().isTerracottaClustered() && context != null) {
return (CacheLockProvider) context;
} else {
return new StripedReadWriteLockSync(stripes);
}
}
内容来源于网络,如有侵权,请联系作者删除!