You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

Starting point for a Camel Route. Start a route with a given Endpoint. The Endpoint can be from one of the many Camel Components. The component creates Camel Exchanges from their respective Sources and puts them into the route.

Syntax

Java

from(String uri)

Parameter

Description

uri

URI describing a Camel Endpoint

from(Endpoint endPoint)

Parameter

Description

uri

URI describing a Camel Endpoint

Spring XML

<from uri=""/>

Parameter

Description

uri

URI describing a Camel Endpoint

Examples

Start a route with the File Endpoint. Each file in the directory creates an Exchange that is put into the camel route.

Java

 A camel route is started using from inside the configure method of the class RouteBuilder.

from("file:c:/in")

 Spring XML Schema

The route is defined inside a CamelContext.

<route>
  <from uri="file:c:/in" />
</route>
  • No labels