class SecretFromPathReader implements Supplier<Optional<Secret>> {

    static SecretFromPathReader of(final Path path) {
        checkNotNull(path, "Secret path");
        final String secretName = String.valueOf(path.getName(path.getNameCount() - 1));
        return of(checkNotNull(secretName, "Secret name"), path);
    }

    private  SecretFromPathReader(final String theSecretName, final Path thePath);

}