Codota Logo
org.eclipse.persistence.descriptors.invalidation
Code IndexAdd Codota to your IDE (free)

How to use org.eclipse.persistence.descriptors.invalidation

Best Java code snippets using org.eclipse.persistence.descriptors.invalidation (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
StringBuilder s =
  • Codota Iconnew StringBuilder()
  • Codota Iconnew StringBuilder(32)
  • Codota IconString str;new StringBuilder(str)
  • Smart code suggestions by Codota
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * PUBLIC:
 * Construct a daily policy that will allow objects to expire at a specific time of day.
 * Provide the hour, minute, second and millisecond.  Objects that make use of this policy
 * will be set to expire at that exact time every day.
 */
public DailyCacheInvalidationPolicy(int hour, int minute, int second, int millisecond) {
  setExpiryTime(hour, minute, second, millisecond);
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * PUBLIC:
 * Build a QueryResultsCachePolicy with the default settings
 * By default there is no invalidation of query results and the maximum
 * number of results sets is 100.
 */
public QueryResultsCachePolicy() {
  this(new NoExpiryCacheInvalidationPolicy(), 100);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Return the remaining life of this object
 */
public long getRemainingValidTime(CacheKey key) {
  long expiryTime = getExpiryTimeInMillis(key);
  long remainingTime = expiryTime - System.currentTimeMillis();
  if (remainingTime > 0) {
    return remainingTime;
  }
  return 0;
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * INTERNAL:
 * Return the next expiry time.
 */
public long getExpiryTimeInMillis(CacheKey key) {
  incrementExpiry();
  return this.expiryTime.getTimeInMillis();
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * INTERNAL:
 * return true if this object is expire, false otherwise.
 */
public abstract boolean isInvalidated(CacheKey key, long currentTimeMillis);
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Return true if this object is set as invalid or has expired.
 */
public boolean isInvalidated(CacheKey key, long currentTimeMillis) {
  if (key.getInvalidationState() == CacheKey.CACHE_KEY_INVALID) {
    return true;
  }
  return getExpiryTimeInMillis(key) <= currentTimeMillis;
}
origin: com.haulmont.thirdparty/eclipselink

  public Object clone() {
    TimeToLiveCacheInvalidationPolicy clone = null;

    try {
      clone = (TimeToLiveCacheInvalidationPolicy)super.clone();
      clone.timeToLive = this.timeToLive;
    } catch (Exception exception) {
      throw new InternalError("clone failed");
    }

    return clone;
  }
}
origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * PUBLIC:
 * Build a QueryResultsCachePolicy and supply a maximum for the number of results sets.
 * Results will be set not to expire in the cache.
 */
public QueryResultsCachePolicy(int maximumResultSets) {
  this(new NoExpiryCacheInvalidationPolicy(), maximumResultSets);
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * PUBLIC:
 * Construct a daily policy that will allow objects to expire at a specific time of day.
 * Provide the hour, minute, second and millisecond.  Objects that make use of this policy
 * will be set to expire at that exact time every day.
 */
public DailyCacheInvalidationPolicy(int hour, int minute, int second, int millisecond) {
  setExpiryTime(hour, minute, second, millisecond);
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * INTERNAL:
 * Return the remaining life of this object
 */
public long getRemainingValidTime(CacheKey key) {
  long expiryTime = getExpiryTimeInMillis(key);
  long remainingTime = expiryTime - System.currentTimeMillis();
  if (remainingTime > 0) {
    return remainingTime;
  }
  return 0;
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Return the next expiry time.
 */
public long getExpiryTimeInMillis(CacheKey key) {
  incrementExpiry();
  return this.expiryTime.getTimeInMillis();
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

  public Object clone() {
    TimeToLiveCacheInvalidationPolicy clone = null;

    try {
      clone = (TimeToLiveCacheInvalidationPolicy)super.clone();
      clone.timeToLive = this.timeToLive;
    } catch (Exception exception) {
      throw new InternalError("clone failed");
    }

    return clone;
  }
}
origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * PUBLIC:
 * Build a QueryResultsCachePolicy with the default settings
 * By default there is no invalidation of query results and the maximum
 * number of results sets is 100.
 */
public QueryResultsCachePolicy() {
  this(new NoExpiryCacheInvalidationPolicy(), 100);
}
origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * PUBLIC:
 * Construct a daily policy that will allow objects to expire at a specific time of day.
 * Provide the hour, minute, second and millisecond.  Objects that make use of this policy
 * will be set to expire at that exact time every day.
 */
public DailyCacheInvalidationPolicy(int hour, int minute, int second, int millisecond) {
  setExpiryTime(hour, minute, second, millisecond);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * PUBLIC:
 * Build a QueryResultsCachePolicy with the default settings
 * By default there is no invalidation of query results and the maximum
 * number of results sets is 100.
 */
public QueryResultsCachePolicy() {
  this(new NoExpiryCacheInvalidationPolicy(), 100);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * PUBLIC:
 * Return the CacheInvalidationPolicy for this descriptor
 * For uninitialized cache invalidation policies, this will return a NoExpiryCacheInvalidationPolicy
 * @return CacheInvalidationPolicy
 * @see org.eclipse.persistence.descriptors.invalidation.CacheInvalidationPolicy
 */
public CacheInvalidationPolicy getCacheInvalidationPolicy() {
  if (cacheInvalidationPolicy == null) {
    cacheInvalidationPolicy = new NoExpiryCacheInvalidationPolicy();
  }
  return cacheInvalidationPolicy;
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * PUBLIC:
 * Return the CacheInvalidationPolicy for this descriptor
 * For uninitialized cache invalidation policies, this will return a NoExpiryCacheInvalidationPolicy
 * @return CacheInvalidationPolicy
 * @see org.eclipse.persistence.descriptors.invalidation.CacheInvalidationPolicy
 */
public CacheInvalidationPolicy getCacheInvalidationPolicy() {
  if (cacheInvalidationPolicy == null) {
    cacheInvalidationPolicy = new NoExpiryCacheInvalidationPolicy();
  }
  return cacheInvalidationPolicy;
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * PUBLIC:
 * Build a QueryResultsCachePolicy and supply a maximum for the number of results sets.
 * Results will be set not to expire in the cache.
 */
public QueryResultsCachePolicy(int maximumResultSets) {
  this(new NoExpiryCacheInvalidationPolicy(), maximumResultSets);
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * PUBLIC:
 * Build a QueryResultsCachePolicy and supply a maximum for the number of results sets.
 * Results will be set not to expire in the cache.
 */
public QueryResultsCachePolicy(int maximumResultSets) {
  this(new NoExpiryCacheInvalidationPolicy(), maximumResultSets);
}
origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * PUBLIC:
 * Return the CacheInvalidationPolicy for this descriptor
 * For uninitialized cache invalidation policies, this will return a NoExpiryCacheInvalidationPolicy
 * @return CacheInvalidationPolicy
 * @see org.eclipse.persistence.descriptors.invalidation.CacheInvalidationPolicy
 */
public CacheInvalidationPolicy getCacheInvalidationPolicy() {
  if (cacheInvalidationPolicy == null) {
    cacheInvalidationPolicy = new NoExpiryCacheInvalidationPolicy();
  }
  return cacheInvalidationPolicy;
}
org.eclipse.persistence.descriptors.invalidation

Most used classes

  • CacheInvalidationPolicy
    PUBLIC: A CacheInvalidationPolicy is used to set objects in TopLink's identity maps to be invalid fo
  • DailyCacheInvalidationPolicy
    PUBLIC: A CacheInvalidationPolicy that allows objects to expire every day at a specific time. A dail
  • NoExpiryCacheInvalidationPolicy
    PUBLIC: A cache invalidation policy in which no objects will expire. The only way for objects to bec
  • TimeToLiveCacheInvalidationPolicy
    PUBLIC: A CacheInvalidationPolicy which allows objects to live for a specific amount of time after t
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now