From e6093a313b8d4970dfe2826bd539c777e51c9aef Mon Sep 17 00:00:00 2001 From: Decebal Suiu Date: Wed, 13 Nov 2019 19:46:08 +0200 Subject: Add javadoc --- .../main/java/org/pf4j/processor/ExtensionAnnotationProcessor.java | 6 ++++++ pf4j/src/main/java/org/pf4j/processor/ExtensionStorage.java | 4 ++++ pf4j/src/main/java/org/pf4j/processor/LegacyExtensionStorage.java | 2 ++ .../java/org/pf4j/processor/ServiceProviderExtensionStorage.java | 2 ++ 4 files changed, 14 insertions(+) (limited to 'pf4j') diff --git a/pf4j/src/main/java/org/pf4j/processor/ExtensionAnnotationProcessor.java b/pf4j/src/main/java/org/pf4j/processor/ExtensionAnnotationProcessor.java index 55bbbc2..e8629bc 100644 --- a/pf4j/src/main/java/org/pf4j/processor/ExtensionAnnotationProcessor.java +++ b/pf4j/src/main/java/org/pf4j/processor/ExtensionAnnotationProcessor.java @@ -40,6 +40,11 @@ import java.util.Set; import java.util.TreeSet; /** + * Processes {@link Extension} annotations and generates an {@link ExtensionStorage}. + * You can specify the concrete {@link ExtensionStorage} via processor's environment options + * ({@link ProcessingEnvironment#getOptions()}) or system property. + * In both variants the option/property name is {@code pf4j.storageClassName}. + * * @author Decebal Suiu */ public class ExtensionAnnotationProcessor extends AbstractProcessor { @@ -241,4 +246,5 @@ public class ExtensionAnnotationProcessor extends AbstractProcessor { return storage; } + } diff --git a/pf4j/src/main/java/org/pf4j/processor/ExtensionStorage.java b/pf4j/src/main/java/org/pf4j/processor/ExtensionStorage.java index 5088068..20a684f 100644 --- a/pf4j/src/main/java/org/pf4j/processor/ExtensionStorage.java +++ b/pf4j/src/main/java/org/pf4j/processor/ExtensionStorage.java @@ -21,6 +21,10 @@ import java.util.Map; import java.util.Set; /** + * It's a storage (database) that persists {@link org.pf4j.Extension}s. + * The standard operations supported by storage are {@link #read} and {@link #write}. + * The storage is populated by {@link ExtensionAnnotationProcessor}. + * * @author Decebal Suiu */ public abstract class ExtensionStorage { diff --git a/pf4j/src/main/java/org/pf4j/processor/LegacyExtensionStorage.java b/pf4j/src/main/java/org/pf4j/processor/LegacyExtensionStorage.java index 3f9c61b..38ebfb5 100644 --- a/pf4j/src/main/java/org/pf4j/processor/LegacyExtensionStorage.java +++ b/pf4j/src/main/java/org/pf4j/processor/LegacyExtensionStorage.java @@ -31,6 +31,8 @@ import java.util.Set; import java.util.regex.Pattern; /** + * Stores {@link org.pf4j.Extension}s in {@code META-INF/extensions.idx}. + * * @author Decebal Suiu */ public class LegacyExtensionStorage extends ExtensionStorage { diff --git a/pf4j/src/main/java/org/pf4j/processor/ServiceProviderExtensionStorage.java b/pf4j/src/main/java/org/pf4j/processor/ServiceProviderExtensionStorage.java index b087a4e..7e07cd0 100644 --- a/pf4j/src/main/java/org/pf4j/processor/ServiceProviderExtensionStorage.java +++ b/pf4j/src/main/java/org/pf4j/processor/ServiceProviderExtensionStorage.java @@ -31,6 +31,8 @@ import java.util.Set; import java.util.regex.Pattern; /** + * Stores {@link org.pf4j.Extension}s in {@code META-INF/services}. + * * @author Decebal Suiu */ public class ServiceProviderExtensionStorage extends ExtensionStorage { -- cgit v1.2.3