class MavenInvokerRequester extends IArtifactRequester {

    @Override
    public Optional<File> requestFile(Coordinate mavenCoordinate, Path targetDirectory, ClassifierInformation classifierInformation) {

        File expectedJarFile = getExpectedJarFile(mavenCoordinate, targetDirectory, classifierInformation);

        if (expectedJarFile.exists()) {
            LOGGER.debug("The file " + expectedJarFile + " already exists and won't be downloaded again");
            return Optional.of(expectedJarFile);
        }

        LOGGER.debug("Requesting artifact with id " + mavenCoordinate.toString());
        boolean requestSuccessful = callMavenInvoker(mavenCoordinate, targetDirectory, classifierInformation.classifier);

        String jarType = classifierInformation.isSource ? "sources jar" : classifierInformation.classifier + " jar";
        if (!requestSuccessful) {
            LOGGER.warn("Failed to find " + jarType + ": Artifact " + mavenCoordinate.toString() + " not found in repo.");
            return Optional.empty();
        } else if (!expectedJarFile.exists()) {
            LOGGER.warn("Failed to find " + jarType + ": Maven call succeeded but Artifact was not generated in the expected place.");
            return Optional.empty();
        }

        return Optional.of(getExpectedJarFile(mavenCoordinate, targetDirectory, classifierInformation));
    }

    public  MavenInvokerRequester(File basedir);
    public  MavenInvokerRequester(File basedir, URL sourceRepositoryUrl);
    public  MavenInvokerRequester(File basedir, DefaultInvoker defaultInvoker, Optional<URL> sourceRepositoryUrl);

}