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

com.github.dreamhead.moco.config.MocoFileRootConfig Maven / Gradle / Ivy

Go to download

Moco is an easy setup stub framework, mainly focusing on testing and integration.

There is a newer version: 1.5.0
Show newest version
package com.github.dreamhead.moco.config;

import com.github.dreamhead.moco.MocoConfig;

import static com.github.dreamhead.moco.util.Files.join;

public class MocoFileRootConfig implements MocoConfig {
    private final String fileRoot;

    public MocoFileRootConfig(final String fileRoot) {
        this.fileRoot = fileRoot;
    }

    @Override
    public boolean isFor(final String id) {
        return FILE_ID.equalsIgnoreCase(id);
    }

    @Override
    public String apply(final String filename) {
        return join(this.fileRoot, filename);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy