@ThreadSafe @Singleton public final class HashCodeImplementationRegistry extends Object implements IHashCodeImplementationRegistry
IHashCodeImplementation
implementations.| Modifier and Type | Method and Description |
|---|---|
<T> IHashCodeImplementation<T> |
getBestMatchingHashCodeImplementation(Class<T> aClass) |
static int |
getHashCode(Object aObj) |
static HashCodeImplementationRegistry |
getInstance() |
static boolean |
isInstantiated() |
<T> void |
registerHashCodeImplementation(Class<T> aClass,
IHashCodeImplementation<T> aImpl)
Register a new hashCode implementation
|
void |
reinitialize() |
EChange |
unregisterHashCodeImplementation(Class<?> aClass) |
public static boolean isInstantiated()
@Nonnull public static HashCodeImplementationRegistry getInstance()
public <T> void registerHashCodeImplementation(@Nonnull Class<T> aClass, @Nonnull IHashCodeImplementation<T> aImpl)
IHashCodeImplementationRegistryregisterHashCodeImplementation in interface IHashCodeImplementationRegistryT - Type to registeraClass - The class for which the hashCode implementation is validaImpl - The main implementation@Nonnull public EChange unregisterHashCodeImplementation(@Nonnull Class<?> aClass)
@Nullable public <T> IHashCodeImplementation<T> getBestMatchingHashCodeImplementation(@Nullable Class<T> aClass)
public void reinitialize()
Copyright © 2014–2020 Philip Helger. All rights reserved.