From a956aec5fc9a08159f6b2ee3757a63ef75653e92 Mon Sep 17 00:00:00 2001 From: Paul Schaub Date: Wed, 24 Aug 2022 14:09:20 +0200 Subject: [PATCH] Add documentation to BaseDirectoryProvider --- .../main/java/pgp/cert_d/BaseDirectoryProvider.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/pgp-cert-d-java/src/main/java/pgp/cert_d/BaseDirectoryProvider.java b/pgp-cert-d-java/src/main/java/pgp/cert_d/BaseDirectoryProvider.java index 0a24084..386a5c7 100644 --- a/pgp-cert-d-java/src/main/java/pgp/cert_d/BaseDirectoryProvider.java +++ b/pgp-cert-d-java/src/main/java/pgp/cert_d/BaseDirectoryProvider.java @@ -6,6 +6,16 @@ package pgp.cert_d; import java.io.File; +/** + * Provider class that is responsible for resolving the pgp.cert.d base directory of the system. + * The result can be overwritten by setting the
PGP_CERT_D
environment variable. + * If this variable is not set, the system-specific default directory will be returned. + * + * On Windows systems, this is
%APPDATA%\pgp.cert.d
. + * On Linux systems it is either
$XDG_DATA_HOME/pgp.cert.d
or, if
$XDG_DATA_HOME
is not set, + * it is
$HOME/.local/share/pgp.cert.d
+ * On Mac systems it is
$HOME/Library/Application Support/pgp.cert.d
. + */ public class BaseDirectoryProvider { public static File getDefaultBaseDir() {