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

com.tangosol.coherence.config.scheme.AbstractLocalCachingScheme Maven / Gradle / Ivy

There is a newer version: 24.09
Show newest version
/*
 * Copyright (c) 2000, 2020, Oracle and/or its affiliates.
 *
 * Licensed under the Universal Permissive License v 1.0 as shown at
 * http://oss.oracle.com/licenses/upl.
 */
package com.tangosol.coherence.config.scheme;

import com.tangosol.coherence.config.builder.BuilderCustomization;
import com.tangosol.coherence.config.builder.NamedEventInterceptorBuilder;
import com.tangosol.coherence.config.builder.ParameterizedBuilder;

import com.tangosol.net.CacheService;

import java.util.Collections;
import java.util.List;

/**
 * The {@link AbstractLocalCachingScheme} is provides common functionality
 * for local caching schemes, including local-scheme, external-scheme, etc.
 *
 * @author pfm  2011.12.28
 * @since Coherence 12.1.2
 */
public abstract class AbstractLocalCachingScheme
        extends AbstractCachingScheme
        implements BuilderCustomization
    {
    // ----- ServiceScheme interface  ---------------------------------------

    /**
     * {@inheritDoc}
     */
    @Override
    public String getServiceType()
        {
        return CacheService.TYPE_LOCAL;
        }

    /**
     * {@inheritDoc}
     */
    @Override
    public List getEventInterceptorBuilders()
        {
        return Collections.EMPTY_LIST;
        }

    // ----- ServiceBuilder interface ---------------------------------------

    /**
     * {@inheritDoc}
     */
    @Override
    public boolean isRunningClusterNeeded()
        {
        return false;
        }

    // ----- BuilderCustomization interface ---------------------------------

    /**
     * {@inheritDoc}
     */
    @Override
    public ParameterizedBuilder getCustomBuilder()
        {
        return m_bldrCustom;
        }

    /**
     * {@inheritDoc}
     */
    public void setCustomBuilder(ParameterizedBuilder bldr)
        {
        m_bldrCustom = bldr;
        }

    // ----- data members ---------------------------------------------------

    /**
     * The {@link ParameterizedBuilder} used to build the custom instance.
     */
    private ParameterizedBuilder m_bldrCustom;
    }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy