Interface LanguageResolver
public interface LanguageResolver
SPI strategy for resolving a
Language implementation by name in a loosely coupled way.
The default implementation first checks the Camel Registry for a bean registered under the language name,
then falls back to the classpath service files under META-INF/services/org/apache/camel/language/. Custom
resolvers can alias language names, redirect to a different implementation, or integrate with a non-classpath
language registry. Multiple resolvers can be registered on CamelContext; they are tried in
priority order until one returns a non-null result or NoSuchLanguageException is thrown.
See Languages in the Camel user manual.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionresolveLanguage(String name, CamelContext context) Resolves the given language.
-
Method Details
-
resolveLanguage
Resolves the given language.- Parameters:
name- the name of the languagecontext- the camel context- Returns:
- the resolved language
- Throws:
NoSuchLanguageException- is thrown if language could not be resolved
-