Interface TypeAliasResolver<S,A>
public interface TypeAliasResolver<S,A>
Type resolver able to adapt an alias type to a given source type. Used in
ReferenceResolver to
auto resolve types that can act as an alias interchangeably to a given type.- Author:
- Christoph Deppisch
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final org.slf4j.LoggerLoggerstatic final Map<String,TypeAliasResolver<?, ?>> static final StringType alias resolver resource lookup pathstatic final TypeResolverType resolver to find custom type alias resolvers on classpath via resource path lookup -
Method Summary
Modifier and TypeMethodDescriptionbooleanisAliasFor(Class<?> sourceType) static Map<String,TypeAliasResolver<?, ?>> lookup()Resolves all available type alias resolvers from resource path lookup.static Optional<TypeAliasResolver<?,?>> Resolves type alias resolver from resource path lookup with given resource name.
-
Field Details
-
logger
static final org.slf4j.Logger loggerLogger -
RESOURCE_PATH
Type alias resolver resource lookup path- See Also:
-
TYPE_RESOLVER
Type resolver to find custom type alias resolvers on classpath via resource path lookup -
resolvers
-
-
Method Details
-
lookup
Resolves all available type alias resolvers from resource path lookup. Scans classpath for type alias resolver meta information and instantiates those resolvers.- Returns:
-
lookup
Resolves type alias resolver from resource path lookup with given resource name. Scans classpath for type alias resolver meta information with given name and returns instance of type alias resolver. Returns optional instead of throwing exception when no type alias resolver could be found.- Parameters:
resolver-- Returns:
-
isAliasFor
-
adapt
-
getAliasType
-