Harmonize RuntimeHintsRegistrar implementations
Closes gh-28801
This commit is contained in:
@@ -30,7 +30,7 @@ import org.springframework.lang.Nullable;
|
||||
* @author Phillip Webb
|
||||
* @since 6.0
|
||||
*/
|
||||
class CoreAnnotationsRuntimeHintsRegistrar implements RuntimeHintsRegistrar {
|
||||
class CoreAnnotationsRuntimeHints implements RuntimeHintsRegistrar {
|
||||
|
||||
@Override
|
||||
public void registerHints(RuntimeHints hints, @Nullable ClassLoader classLoader) {
|
||||
@@ -40,7 +40,7 @@ import org.springframework.util.ClassUtils;
|
||||
* @since 6.0
|
||||
* @see SpringFactoriesLoader
|
||||
*/
|
||||
class SpringFactoriesLoaderRuntimeHintsRegistrar implements RuntimeHintsRegistrar {
|
||||
class SpringFactoriesLoaderRuntimeHints implements RuntimeHintsRegistrar {
|
||||
|
||||
private static final List<String> RESOURCE_LOCATIONS =
|
||||
List.of(SpringFactoriesLoader.FACTORIES_RESOURCE_LOCATION);
|
||||
@@ -48,7 +48,7 @@ class SpringFactoriesLoaderRuntimeHintsRegistrar implements RuntimeHintsRegistra
|
||||
private static final Consumer<TypeHint.Builder> HINT = builder ->
|
||||
builder.withMembers(MemberCategory.INVOKE_DECLARED_CONSTRUCTORS);
|
||||
|
||||
private static final Log logger = LogFactory.getLog(SpringFactoriesLoaderRuntimeHintsRegistrar.class);
|
||||
private static final Log logger = LogFactory.getLog(SpringFactoriesLoaderRuntimeHints.class);
|
||||
|
||||
|
||||
@Override
|
||||
@@ -1,3 +1,3 @@
|
||||
org.springframework.aot.hint.RuntimeHintsRegistrar=\
|
||||
org.springframework.aot.hint.support.CoreAnnotationsRuntimeHintsRegistrar,\
|
||||
org.springframework.aot.hint.support.SpringFactoriesLoaderRuntimeHintsRegistrar
|
||||
org.springframework.aot.hint.support.CoreAnnotationsRuntimeHints,\
|
||||
org.springframework.aot.hint.support.SpringFactoriesLoaderRuntimeHints
|
||||
|
||||
@@ -31,13 +31,13 @@ import org.springframework.util.ClassUtils;
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
/**
|
||||
* Tests for {@link CoreAnnotationsRuntimeHintsRegistrar}.
|
||||
* Tests for {@link CoreAnnotationsRuntimeHints}.
|
||||
*
|
||||
* @author Phillip Webb
|
||||
*/
|
||||
class CoreAnnotationsRuntimeHintsRegistrarTests {
|
||||
class CoreAnnotationsRuntimeHintsTests {
|
||||
|
||||
private RuntimeHints hints = new RuntimeHints();
|
||||
private final RuntimeHints hints = new RuntimeHints();
|
||||
|
||||
@BeforeEach
|
||||
void setup() {
|
||||
@@ -31,11 +31,11 @@ import org.springframework.util.ClassUtils;
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
/**
|
||||
* Tests for {@link SpringFactoriesLoaderRuntimeHintsRegistrar}.
|
||||
* Tests for {@link SpringFactoriesLoaderRuntimeHints}.
|
||||
*
|
||||
* @author Phillip Webb
|
||||
*/
|
||||
class SpringFactoriesLoaderRuntimeHintsRegistrarTests {
|
||||
class SpringFactoriesLoaderRuntimeHintsTests {
|
||||
|
||||
private RuntimeHints hints;
|
||||
|
||||
Reference in New Issue
Block a user