Package com.google.gerrit.server.cache
Class PerThreadCache.Key<T>
- java.lang.Object
-
- com.google.gerrit.server.cache.PerThreadCache.Key<T>
-
- Enclosing class:
- PerThreadCache
public static final class PerThreadCache.Key<T> extends Object
Unique key for key-value mappings stored in PerThreadCache. The key is based on the value's class and a list of identifiers that in combination uniquely set the object apart form others of the same class.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <T> PerThreadCache.Key<T>
create(Class<T> clazz, Object identifier)
Returns a key based on the value's class and an identifier that uniquely identify the value.static <T> PerThreadCache.Key<T>
create(Class<T> clazz, Object... identifiers)
Returns a key based on the value's class and a set of identifiers that uniquely identify the value.boolean
equals(Object o)
int
hashCode()
-
-
-
Method Detail
-
create
public static <T> PerThreadCache.Key<T> create(Class<T> clazz, Object identifier)
Returns a key based on the value's class and an identifier that uniquely identify the value. The identifier needs to implementequals()
and .
-
create
public static <T> PerThreadCache.Key<T> create(Class<T> clazz, Object... identifiers)
Returns a key based on the value's class and a set of identifiers that uniquely identify the value. Identifiers need to implementequals()
and .
-
-