@@ -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; | |||
} | |||
} |
@@ -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 { |
@@ -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 { |
@@ -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 { |