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

com.chutneytesting.task.domain.TaskTemplateLoaders Maven / Gradle / Ivy

There is a newer version: 3.0.0
Show newest version
package com.chutneytesting.task.domain;

import java.util.List;
import java.util.stream.Collectors;

/**
 * A Collection of loaders, allow to get all {@link TaskTemplate} in order, respecting each {@link TaskTemplateLoader} precedence.
 */
public class TaskTemplateLoaders {

    private final List loaders;

    public TaskTemplateLoaders(List loaders) {
        this.loaders = loaders;
    }

    List orderedTemplates() {
        return loaders
            .stream()
            .flatMap(delegate -> delegate.load().stream())
            .collect(Collectors.toList());
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy