Class SimpleLocality

  • All Implemented Interfaces:
    Locality

    public class SimpleLocality
    extends Object
    implements Locality
    Simple Locality implementation that uses a static value.
    Author:
    Paul Ferraro
    • Constructor Detail

      • SimpleLocality

        public SimpleLocality​(boolean local)
    • Method Detail

      • isLocal

        public boolean isLocal​(Object key)
        Description copied from interface: Locality
        Indicates whether the current node is the primary owner of the specified cache key. For local caches, this method will always return true.
        Specified by:
        isLocal in interface Locality
        Parameters:
        key - a cache key
        Returns:
        true, if the current node is the primary owner of the specified cache key, false otherwise