net.sf.ehcache.Cache.putInternal()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(6.4k)|赞(0)|评价(0)|浏览(83)

本文整理了Java中net.sf.ehcache.Cache.putInternal()方法的一些代码示例,展示了Cache.putInternal()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Cache.putInternal()方法的具体详情如下:
包路径:net.sf.ehcache.Cache
类名称:Cache
方法名:putInternal

Cache.putInternal介绍

暂无

代码示例

代码示例来源:origin: net.sf.ehcache/ehcache

/**
 * {@inheritDoc}
 */
public void putWithWriter(Element element) throws IllegalArgumentException, IllegalStateException, CacheException {
  putInternal(element, false, true);
}

代码示例来源:origin: net.sf.ehcache/ehcache

/**
 * Put an element in the cache.
 * <p>
 * Resets the access statistics on the element, which would be the case if it has previously been
 * gotten from a cache, and is now being put back.
 * <p>
 * Also notifies the CacheEventListener that:
 * <ul>
 * <li>the element was put, but only if the Element was actually put.
 * <li>if the element exists in the cache, that an update has occurred, even if the element would be expired
 * if it was requested
 * </ul>
 * Caches which use synchronous replication can throw RemoteCacheException here if the replication to the cluster fails.
 * This exception should be caught in those circumstances.
 *
 * @param element                     A cache Element. If Serializable it can fully participate in replication and the DiskStore. If it is
 *                                    <code>null</code> or the key is <code>null</code>, it is ignored as a NOOP.
 * @param doNotNotifyCacheReplicators whether the put is coming from a doNotNotifyCacheReplicators cache peer, in which case this put should not initiate a
 *                                    further notification to doNotNotifyCacheReplicators cache peers
 * @throws IllegalStateException    if the cache is not {@link Status#STATUS_ALIVE}
 * @throws IllegalArgumentException if the element is null
 */
public final void put(Element element, boolean doNotNotifyCacheReplicators) throws IllegalArgumentException,
    IllegalStateException, CacheException {
  putInternal(element, doNotNotifyCacheReplicators, false);
}

代码示例来源:origin: org.sonatype.nexus.bundles/org.sonatype.nexus.bundles.ehcache

/**
 * {@inheritDoc}
 */
public void putWithWriter(Element element) throws IllegalArgumentException, IllegalStateException, CacheException {
  putInternal(element, false, true);
}

代码示例来源:origin: net.sf.ehcache.internal/ehcache-core

/**
 * {@inheritDoc}
 */
public void putWithWriter(Element element) throws IllegalArgumentException, IllegalStateException, CacheException {
  putInternal(element, false, true);
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.ehcache

/**
 * {@inheritDoc}
 */
public void putWithWriter(Element element) throws IllegalArgumentException, IllegalStateException, CacheException {
  putInternal(element, false, true);
}

代码示例来源:origin: net.sf.ehcache.internal/ehcache-core

/**
 * Put an element in the cache.
 * <p>
 * Resets the access statistics on the element, which would be the case if it has previously been
 * gotten from a cache, and is now being put back.
 * <p>
 * Also notifies the CacheEventListener that:
 * <ul>
 * <li>the element was put, but only if the Element was actually put.
 * <li>if the element exists in the cache, that an update has occurred, even if the element would be expired
 * if it was requested
 * </ul>
 * Caches which use synchronous replication can throw RemoteCacheException here if the replication to the cluster fails.
 * This exception should be caught in those circumstances.
 *
 * @param element                     A cache Element. If Serializable it can fully participate in replication and the DiskStore. If it is
 *                                    <code>null</code> or the key is <code>null</code>, it is ignored as a NOOP.
 * @param doNotNotifyCacheReplicators whether the put is coming from a doNotNotifyCacheReplicators cache peer, in which case this put should not initiate a
 *                                    further notification to doNotNotifyCacheReplicators cache peers
 * @throws IllegalStateException    if the cache is not {@link Status#STATUS_ALIVE}
 * @throws IllegalArgumentException if the element is null
 */
public final void put(Element element, boolean doNotNotifyCacheReplicators) throws IllegalArgumentException,
    IllegalStateException, CacheException {
  putInternal(element, doNotNotifyCacheReplicators, false);
}

代码示例来源:origin: org.sonatype.nexus.bundles/org.sonatype.nexus.bundles.ehcache

/**
 * Put an element in the cache.
 * <p/>
 * Resets the access statistics on the element, which would be the case if it has previously been
 * gotten from a cache, and is now being put back.
 * <p/>
 * Also notifies the CacheEventListener that:
 * <ul>
 * <li>the element was put, but only if the Element was actually put.
 * <li>if the element exists in the cache, that an update has occurred, even if the element would be expired
 * if it was requested
 * </ul>
 * Caches which use synchronous replication can throw RemoteCacheException here if the replication to the cluster fails.
 * This exception should be caught in those circumstances.
 *
 * @param element                     A cache Element. If Serializable it can fully participate in replication and the DiskStore. If it is
 *                                    <code>null</code> or the key is <code>null</code>, it is ignored as a NOOP.
 * @param doNotNotifyCacheReplicators whether the put is coming from a doNotNotifyCacheReplicators cache peer, in which case this put should not initiate a
 *                                    further notification to doNotNotifyCacheReplicators cache peers
 * @throws IllegalStateException    if the cache is not {@link Status#STATUS_ALIVE}
 * @throws IllegalArgumentException if the element is null
 */
public final void put(Element element, boolean doNotNotifyCacheReplicators) throws IllegalArgumentException,
    IllegalStateException, CacheException {
  putInternal(element, doNotNotifyCacheReplicators, false);
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.ehcache

/**
 * Put an element in the cache.
 * <p/>
 * Resets the access statistics on the element, which would be the case if it has previously been
 * gotten from a cache, and is now being put back.
 * <p/>
 * Also notifies the CacheEventListener that:
 * <ul>
 * <li>the element was put, but only if the Element was actually put.
 * <li>if the element exists in the cache, that an update has occurred, even if the element would be expired
 * if it was requested
 * </ul>
 * Caches which use synchronous replication can throw RemoteCacheException here if the replication to the cluster fails.
 * This exception should be caught in those circumstances.
 *
 * @param element                     A cache Element. If Serializable it can fully participate in replication and the DiskStore. If it is
 *                                    <code>null</code> or the key is <code>null</code>, it is ignored as a NOOP.
 * @param doNotNotifyCacheReplicators whether the put is coming from a doNotNotifyCacheReplicators cache peer, in which case this put should not initiate a
 *                                    further notification to doNotNotifyCacheReplicators cache peers
 * @throws IllegalStateException    if the cache is not {@link Status#STATUS_ALIVE}
 * @throws IllegalArgumentException if the element is null
 */
public final void put(Element element, boolean doNotNotifyCacheReplicators) throws IllegalArgumentException,
    IllegalStateException, CacheException {
  putInternal(element, doNotNotifyCacheReplicators, false);
}

相关文章

微信公众号

最新文章

更多

Cache类方法