Interface EndpointConsumerResolver
public interface EndpointConsumerResolver
Implemented by objects that can be resolved to a consumer-facing
Endpoint.
The DSL and annotation processor call resolve(CamelContext) to obtain a concrete Endpoint when an
object used in a from() clause is not itself an endpoint URI string. This allows richer types (for example,
enum constants or wrapper objects) to be used as route input descriptors without requiring string parsing.- Since:
- 3.1
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionresolve(CamelContext context) Resolves this object as an endpoint.<T extends Endpoint>
Tresolve(CamelContext context, Class<T> endpointType) Resolves this object as an endpoint.
-
Method Details
-
resolve
Resolves this object as an endpoint.- Parameters:
context- the camel context- Returns:
- a built
Endpoint - Throws:
NoSuchEndpointException- is thrown if the endpoint
-
resolve
<T extends Endpoint> T resolve(CamelContext context, Class<T> endpointType) throws NoSuchEndpointException Resolves this object as an endpoint.- Parameters:
context- the camel contextendpointType- the expected type- Returns:
- a built
Endpoint - Throws:
NoSuchEndpointException- is thrown if the endpoint
-