2013-09-21 33 views

回答

1

我發現瞭如何與駱駝做到這一點 - 下面是一個例子:

// add our route to the CamelContext 
    context.addRoutes(new RouteBuilder() { 
     public void configure() { 

      from("file:"+getFullPath()+"?noop=true") 
      .process(new Processor() { 

       public void process(Exchange exchange) throws Exception { 

        System.out.println("size is #" +exchange.getProperty("CamelBatchSize")); 
        System.out.println(file.getName()); 

       } 
      }).to("file:/home/anton/tmp/outbox?"); 

     } 
    }); 
+0

任何想法,如何在藍圖中做同樣的事情? – nik

相關問題