All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.wildfly.clustering.infinispan.distribution.SimpleLocality Maven / Gradle / Ivy

/*
 * Copyright The WildFly Authors
 * SPDX-License-Identifier: Apache-2.0
 */

package org.wildfly.clustering.infinispan.distribution;

/**
 * Simple {@link Locality} implementation that uses a static value.
 * @author Paul Ferraro
 */
public class SimpleLocality implements Locality {

    private final boolean local;

    public SimpleLocality(boolean local) {
        this.local = local;
    }

    @Override
    public boolean isLocal(Object key) {
        return this.local;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy