Package org.apache.camel.impl.converter
Class TypeConvertersLoader
- java.lang.Object
-
- org.apache.camel.impl.converter.AnnotationTypeConverterLoader
-
- org.apache.camel.impl.converter.TypeConvertersLoader
-
- All Implemented Interfaces:
org.apache.camel.spi.TypeConverterLoader
public class TypeConvertersLoader extends AnnotationTypeConverterLoader
A type converter loader, that only supports scanning aTypeConvertersclass for methods that has been annotated withConverter.
-
-
Field Summary
-
Fields inherited from class org.apache.camel.impl.converter.AnnotationTypeConverterLoader
META_INF_SERVICES, resolver, visitedClasses, visitedURIs
-
-
Constructor Summary
Constructors Constructor Description TypeConvertersLoader(Class<?> clazz)Creates the loaderTypeConvertersLoader(Object typeConverters)Creates the loader
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected String[]findPackageNames()Finds the names of the packages to search for on the classpath looking for text files on the classpath at theAnnotationTypeConverterLoader.META_INF_SERVICESlocation.-
Methods inherited from class org.apache.camel.impl.converter.AnnotationTypeConverterLoader
acceptClass, filterPackageNamesOnly, filterUnwantedPackage, findPackages, isValidConverterMethod, isValidFallbackConverterMethod, load, loadConverterMethods, registerFallbackTypeConverter, registerTypeConverter
-
-
-
-
Constructor Detail
-
TypeConvertersLoader
public TypeConvertersLoader(Object typeConverters)
Creates the loader- Parameters:
typeConverters- The implementation that has the type converters
-
TypeConvertersLoader
public TypeConvertersLoader(Class<?> clazz)
Creates the loader- Parameters:
clazz- the class with the @Converter annotation and converter methods
-
-
Method Detail
-
findPackageNames
protected String[] findPackageNames() throws IOException
Description copied from class:AnnotationTypeConverterLoaderFinds the names of the packages to search for on the classpath looking for text files on the classpath at theAnnotationTypeConverterLoader.META_INF_SERVICESlocation.- Overrides:
findPackageNamesin classAnnotationTypeConverterLoader- Returns:
- a collection of packages to search for
- Throws:
IOException- is thrown for IO related errors
-
-