Package org.apache.tika.config.loader
Interface ComponentLoader<T>
- Type Parameters:
T- the component type (e.g., Parser, Detector, EncodingDetector)
- All Known Implementing Classes:
AbstractSpiComponentLoader,DetectorLoader,EncodingDetectorLoader,ParserLoader
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Strategy interface for loading components from JSON config.
Implementations handle component-specific concerns like:
- Dependency injection (EncodingDetector into parsers)
- Decorations (mime filtering)
- SPI fallback with exclusions
-
Method Summary
Modifier and TypeMethodDescriptionload(TikaJsonConfig config, LoaderContext context) Load components from the JSON config.
-
Method Details
-
load
Load components from the JSON config.- Parameters:
config- the JSON configurationcontext- shared context with dependencies and utilities- Returns:
- the loaded component (typically a composite)
- Throws:
TikaConfigException- if loading fails
-