Class DeduplicableRegistry


  • public class DeduplicableRegistry
    extends Object
    A registry of deduplicable objects.
    Author:
    Lucian Chirita (lucianc@users.sourceforge.net)
    • Constructor Detail

      • DeduplicableRegistry

        public DeduplicableRegistry()
    • Method Detail

      • deduplicate

        public <T extends Deduplicable> T deduplicate​(T object)
        Search for a duplicate of a given object in the registry, and add the object to the registry if no duplicate found.
        Parameters:
        object - the object to be searched or added
        Returns:
        a duplicate of the object if found, or the passed object if not