Class ConfigurationBeanNameAnnotationResolver
java.lang.Object
com.bobocode.bring.core.annotation.resolver.impl.ConfigurationBeanNameAnnotationResolver
- All Implemented Interfaces:
AnnotationResolver
This class implements the AnnotationResolver interface to resolve
the name of a configuration bean based on the presence of the Configuration annotation.
- Since:
- 1.0
- Author:
- Blyzhnytsia Team
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
isSupported
(Class<?> clazz) Checks if the provided class is supported for resolving.Resolves the name of the configuration bean based on the provided class.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.bobocode.bring.core.annotation.resolver.AnnotationResolver
getSimpleName
-
Constructor Details
-
ConfigurationBeanNameAnnotationResolver
public ConfigurationBeanNameAnnotationResolver()
-
-
Method Details
-
isSupported
Checks if the provided class is supported for resolving.- Specified by:
isSupported
in interfaceAnnotationResolver
- Parameters:
clazz
- The class to be checked for support.- Returns:
true
if the class has the Configuration annotation,false
otherwise.
-
resolve
Resolves the name of the configuration bean based on the provided class.- Specified by:
resolve
in interfaceAnnotationResolver
- Parameters:
clazz
- The class for which the name of the configuration bean needs to be resolved.- Returns:
- A String representing the simple name of the class.
-