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

io.atleon.core.AloFactoryConfig Maven / Gradle / Ivy

package io.atleon.core;

import java.util.Map;

/**
 * Utility for loading {@link AloFactory} implementations
 */
public final class AloFactoryConfig {

    private AloFactoryConfig() {

    }

    public static > AloFactory loadDecorated(
        Map properties,
        Class decoratorSuperType
    ) {
        AloFactory aloFactory = loadDefault();
        return AloDecoratorConfig.load(properties, decoratorSuperType)
            .map(aloFactory::withDecorator)
            .orElse(aloFactory);
    }

    public static  AloFactory loadDefault() {
        return ComposedAlo.factory();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy