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

io.github.splotycode.mosaik.spigotlib.paths.SpigotPathManager Maven / Gradle / Ivy

The newest version!
package io.github.splotycode.mosaik.spigotlib.paths;

import io.github.splotycode.mosaik.runtime.application.ApplicationInfo;
import io.github.splotycode.mosaik.runtime.pathmanager.PathManager;

import java.io.File;

public class SpigotPathManager implements PathManager {

    private File mainDir, logDir;


    @Override
    public File getMainDirectory() {
        if (mainDir == null) {
            mainDir = new File("plugins/" + ApplicationInfo.getImplementingName() + "/");
        }
        return mainDir;
    }

    @Override
    public File getLogDirectory() {
        if (logDir == null) {
            logDir = new File(getMainDirectory(), "Logs/");
        }
        return logDir;
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy