Skip to content
This repository was archived by the owner on Dec 27, 2023. It is now read-only.

Commit d051bb5

Browse files
fix: make FactoryLoader.java methods public (#489)
Co-authored-by: g00563573 <L0kuj;lfyysq>
1 parent 5f0db2f commit d051bb5

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

asto-core/src/main/java/com/artipie/asto/factory/FactoryLoader.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,30 +52,30 @@ protected FactoryLoader(final Class<A> annot, final Map<String, String> env) {
5252
* Default package name.
5353
* @return The name of the default scan package
5454
*/
55-
abstract String defPackage();
55+
public abstract String defPackage();
5656

5757
/**
5858
* Environment parameter to define packages to find factories.
5959
* Package names should be separated by semicolon ';'.
6060
* @return Env param name
6161
*/
62-
abstract String scanPackagesEnv();
62+
public abstract String scanPackagesEnv();
6363

6464
/**
6565
* Find factory by name and create object.
6666
* @param name The factory name
6767
* @param config Configuration
6868
* @return The object
6969
*/
70-
abstract O newObject(String name, C config);
70+
public abstract O newObject(String name, C config);
7171

7272
/**
7373
* Get the name of the factory from provided element. Call {@link Class#getAnnotations()}
7474
* method on the element, filter required annotations and get factory implementation name.
7575
* @param element Element to get annotations from
7676
* @return The name of the factory
7777
*/
78-
abstract String getFactoryName(Class<?> element);
78+
public abstract String getFactoryName(Class<?> element);
7979

8080
/**
8181
* Finds and initiates annotated classes in default and env packages.

asto-core/src/main/java/com/artipie/asto/factory/StoragesLoader.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ public String scanPackagesEnv() {
6969
}
7070

7171
@Override
72-
String getFactoryName(final Class<?> element) {
72+
public String getFactoryName(final Class<?> element) {
7373
return Arrays.stream(element.getAnnotations())
7474
.filter(ArtipieStorageFactory.class::isInstance)
7575
.map(a -> ((ArtipieStorageFactory) a).value())

0 commit comments

Comments
 (0)