Interface TypeSet.Resolver
-
- All Known Implementing Classes:
TypeSet.AbstractResolver
,TypeSet.CurrentPackageResolver
,TypeSet.ExplicitImportResolver
,TypeSet.FullyQualifiedNameResolver
,TypeSet.ImplicitImportResolver
,TypeSet.ImportOnDemandResolver
,TypeSet.PrimitiveTypeResolver
,TypeSet.VoidResolver
- Enclosing class:
- TypeSet
public static interface TypeSet.Resolver
A resolver that can resolve a class by name. The name can be a simple name or a fully qualified name.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
couldResolve(String name)
Checks if the given class could be resolved by this resolver.Class<?>
resolve(String name)
Resolve the class by the given name
-
-
-
Method Detail
-
resolve
Class<?> resolve(String name) throws ClassNotFoundException
Resolve the class by the given name- Parameters:
name
- the name of the class, might be fully classified or not.- Returns:
- the class
- Throws:
ClassNotFoundException
- if the class couldn't be found
-
couldResolve
boolean couldResolve(String name)
Checks if the given class could be resolved by this resolver. Notice, that a resolver's ability to resolve a class does not imply that the class will actually be found and resolved.- Parameters:
name
- the name of the class, might be fully classified or not.- Returns:
- whether the class can be resolved
-
-