1 19 package javax.util.jcache; 20 21 25 public interface Attributes { 26 28 public static final int INVALIDATE_EVENT = 0; 29 33 public static final long DISTRIBUTE = 1; 34 40 public static final long NOFLUSH = 2; 41 46 public static final long REPLY = 4; 47 52 public static final long SYNCHRONIZE = 8; 53 58 public static final long SPOOL = 16; 59 64 public static final long GROUP_TTL_DESTROY = 32; 65 71 public static final long ORIGINAL = 64; 72 73 83 public abstract void setFlags(final long theFlags); 84 85 90 public abstract void setLoader(final CacheLoader aLoader); 91 92 98 public abstract void setVersion(final long aVersion); 99 100 114 public abstract void setTimeToLive(final long ttl) throws InvalidArgumentException; 115 116 135 public abstract void setDefaultTimeToLive(final long ttl) throws InvalidArgumentException; 136 137 public abstract long getDefaultTimeToLive(); 138 139 149 public abstract void setIdleTime(final long idle) throws InvalidArgumentException; 150 151 165 public abstract void setListener(final int event, final CacheEventListener aListener); 166 167 176 public abstract void setSize(final int aSize); 177 178 185 public abstract int getSize(); 186 187 195 public abstract boolean isSet(final long theFlags); 196 197 204 public abstract long getCreateTime(); 205 206 211 public abstract CacheLoader getLoader(); 212 213 218 public abstract long getVersion(); 219 220 225 public abstract long getIdleTime(); 226 227 232 public abstract long getTimeToLive(); 233 234 243 public abstract void reset(); 244 245 250 public abstract void setCreateTime(final long aCreateTime); 251 264 public long timeToSeconds(final int days, final int hours, final int minutes, final int seconds) throws InvalidArgumentException; 265 270 public abstract CacheEventListener getListener(); 271 public void applyAttributes(Attributes attributes); 272 } | Popular Tags |