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

io.bdeploy.common.cfg.ExistingDirectoryValidator Maven / Gradle / Ivy

Go to download

Public API including dependencies, ready to be used for integrations and plugins.

There is a newer version: 7.3.6
Show newest version
package io.bdeploy.common.cfg;

import java.io.File;
import java.nio.file.Path;

import io.bdeploy.common.cfg.Configuration.ValidationMessage;

/**
 * Checks if the given {@link Path} exists and {@link File#isDirectory() is a directory}.
 */
@ValidationMessage("Directory does not exist, but should exist: %s")
public class ExistingDirectoryValidator extends ExistingPathValidator {

    @Override
    public boolean test(String value) {
        return super.test(value) && p.toFile().isDirectory();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy