K - public class CacheSet<K> extends Object implements Set<K>
| Constructor and Description |
|---|
CacheSet()
inclusive: wheter max distance is inclusive or exclusive.
|
CacheSet(int maxItemCount,
boolean allowRenewal) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
_add(K key)
Put operations are done for the current time
|
boolean |
add(K key) |
boolean |
addAll(Collection<? extends K> arg0) |
K |
addAndGetRemoved(K key)
Adds an item, and returns an item that was removed - or null if no item
was removed
|
void |
clear() |
boolean |
contains(Object arg0) |
boolean |
containsAll(Collection<?> arg0) |
boolean |
equals(Object o) |
Integer |
getKeyTime(K key) |
int |
hashCode() |
boolean |
isEmpty() |
Iterator<K> |
iterator()
FIXME Make sure that the iterator's remove method cannot be invoked
directly
|
boolean |
remove(Object arg0) |
boolean |
removeAll(Collection<?> items) |
boolean |
renew(Object key) |
boolean |
retainAll(Collection<?> arg0) |
Set<K> |
setMaxItemCount(int newMaxItemCount)
Sets a new maximum distance.
|
int |
size() |
Object[] |
toArray() |
<X> X[] |
toArray(X[] arg0) |
String |
toString() |
public CacheSet()
public CacheSet(int maxItemCount,
boolean allowRenewal)
public Set<K> setMaxItemCount(int newMaxItemCount)
newMaxItemCount - public boolean renew(Object key)
public K addAndGetRemoved(K key)
key - public boolean add(K key)
public boolean _add(K key)
public boolean addAll(Collection<? extends K> arg0)
public void clear()
public boolean contains(Object arg0)
public boolean containsAll(Collection<?> arg0)
containsAll in interface Collection<K>containsAll in interface Set<K>public boolean isEmpty()
public Iterator<K> iterator()
public boolean remove(Object arg0)
public boolean removeAll(Collection<?> items)
public boolean retainAll(Collection<?> arg0)
public int size()
public Object[] toArray()
public <X> X[] toArray(X[] arg0)
public int hashCode()
public boolean equals(Object o)
Copyright © 2015. All rights reserved.