camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject svn commit: r1422751 - in /camel/trunk/components/camel-bindy/src: main/java/org/apache/camel/dataformat/bindy/ main/java/org/apache/camel/dataformat/bindy/annotation/ main/java/org/apache/camel/dataformat/bindy/csv/ test/java/org/apache/camel/dataform...
Date Mon, 17 Dec 2012 04:40:08 GMT
Author: ningjiang
Date: Mon Dec 17 04:40:05 2012
New Revision: 1422751

URL: http://svn.apache.org/viewvc?rev=1422751&view=rev
Log:
CAMEL-5871 fix the signle quote issue of camel-bindy with thanks to Antonie

Added:
    camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest.java
      - copied, changed from r1422568, camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindyInlinedQuotesCsvUnmarshallTest.java
    camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/model/simple/oneclasssinglequote/
    camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/model/simple/oneclasssinglequote/Order.java
    camel/trunk/components/camel-bindy/src/test/resources/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest-context.xml
Modified:
    camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyCsvFactory.java
    camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/annotation/CsvRecord.java
    camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/csv/BindyCsvDataFormat.java
    camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindyInlinedQuotesCsvUnmarshallTest.java
    camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuotesCsvUnmarshallTest.java
    camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/BindyUnmarshalCommaIssueTest.java
    camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/WeatherModel.java

Modified: camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyCsvFactory.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyCsvFactory.java?rev=1422751&r1=1422750&r2=1422751&view=diff
==============================================================================
--- camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyCsvFactory.java
(original)
+++ camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyCsvFactory.java
Mon Dec 17 04:40:05 2012
@@ -64,6 +64,7 @@ public class BindyCsvFactory extends Bin
     private boolean generateHeaderColumnNames;
     private boolean messageOrdered;
     private String quote;
+    private boolean quoting;
 
     public BindyCsvFactory(PackageScanClassResolver resolver, String... packageNames) throws
Exception {
         super(resolver, packageNames);
@@ -300,11 +301,11 @@ public class BindyCsvFactory extends Bin
                     String res = itx.next();
                     if (res != null) {
                         // the field may be enclosed in quotes if a quote was configured
-                        if (quote != null) {
+                        if (quoting && quote != null) {
                             buffer.append(quote);
                         }
                         buffer.append(res);
-                        if (quote != null) {
+                        if (quoting && quote != null) {
                             buffer.append(quote);
                         }
                     }
@@ -557,6 +558,9 @@ public class BindyCsvFactory extends Bin
                         quote = record.quote();
                         LOG.debug("Quoting columns with: {}", quote);
                     }
+
+                    quoting = record.quoting();
+                    LOG.debug("CSV will be quoted: {}", messageOrdered);
                 }
 
                 if (section != null) {
@@ -622,4 +626,8 @@ public class BindyCsvFactory extends Bin
     public boolean isMessageOrdered() {
         return messageOrdered;
     }
+
+    public String getQuote() {
+        return quote;
+    }
 }

Modified: camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/annotation/CsvRecord.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/annotation/CsvRecord.java?rev=1422751&r1=1422750&r2=1422751&view=diff
==============================================================================
--- camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/annotation/CsvRecord.java
(original)
+++ camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/annotation/CsvRecord.java
Mon Dec 17 04:40:05 2012
@@ -73,6 +73,11 @@ public @interface CsvRecord {
     /**
      * Whether to marshal columns with the given quote character (optional)
      */
-    String quote() default "";
+    String quote() default "\"";
+
+    /**
+     * Indicate if the values must be quoted when marshaling (optional)
+     */
+    boolean quoting() default false;
 
 }

Modified: camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/csv/BindyCsvDataFormat.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/csv/BindyCsvDataFormat.java?rev=1422751&r1=1422750&r2=1422751&view=diff
==============================================================================
--- camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/csv/BindyCsvDataFormat.java
(original)
+++ camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/csv/BindyCsvDataFormat.java
Mon Dec 17 04:40:05 2012
@@ -121,6 +121,7 @@ public class BindyCsvDataFormat extends 
 
         // Retrieve the separator defined to split the record
         String separator = factory.getSeparator();
+        String quote = factory .getQuote();
         ObjectHelper.notNull(separator, "The separator has not been defined in the annotation
@CsvRecord or not instantiated during initModel.");
 
         int count = 0;
@@ -155,7 +156,7 @@ public class BindyCsvDataFormat extends 
                 String[] tokens = line.split(separator, -1);
                 List<String> result = Arrays.asList(tokens);
                 // must unquote tokens before use
-                result = unquoteTokens(result, separator);
+                result = unquoteTokens(result, separator, quote);
 
                 if (result.size() == 0 || result.isEmpty()) {
                     throw new java.lang.IllegalArgumentException("No records have been defined
in the CSV");
@@ -199,7 +200,7 @@ public class BindyCsvDataFormat extends 
      * as will handling fixing broken tokens which may have been split
      * by a separator inside a quote.
      */
-    private List<String> unquoteTokens(List<String> result, String separator)
{
+    private List<String> unquoteTokens(List<String> result, String separator,
String quote) {
         // a current quoted token which we assemble from the broken pieces
         // we need to do this as we use the split method on the String class
         // to split the line using regular expression, and it does not handle
@@ -211,11 +212,11 @@ public class BindyCsvDataFormat extends 
         for (String s : result) {
             boolean startQuote = false;
             boolean endQuote = false;
-            if (s.startsWith("\"") || s.startsWith("'")) {
+            if (s.startsWith(quote)) {
                 s = s.substring(1);
                 startQuote = true;
             }
-            if (s.endsWith("\"") || s.endsWith("'")) {
+            if (s.endsWith(quote)) {
                 s = s.substring(0, s.length() - 1);
                 endQuote = true;
             }

Modified: camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindyInlinedQuotesCsvUnmarshallTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindyInlinedQuotesCsvUnmarshallTest.java?rev=1422751&r1=1422750&r2=1422751&view=diff
==============================================================================
--- camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindyInlinedQuotesCsvUnmarshallTest.java
(original)
+++ camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindyInlinedQuotesCsvUnmarshallTest.java
Mon Dec 17 04:40:05 2012
@@ -24,6 +24,7 @@ import org.apache.camel.Produce;
 import org.apache.camel.ProducerTemplate;
 import org.apache.camel.builder.RouteBuilder;
 import org.apache.camel.component.mock.MockEndpoint;
+import org.apache.camel.dataformat.bindy.model.simple.oneclasssinglequote.Order;
 import org.junit.Assert;
 import org.junit.Test;
 import org.springframework.test.annotation.DirtiesContext;
@@ -56,14 +57,14 @@ public class BindyInlinedQuotesCsvUnmars
         result.assertIsSatisfied();
 
         Map<?, ?> map = (Map<?, ?>) result.getReceivedExchanges().get(0).getIn().getBody(List.class).get(0);
-        BindyDoubleQuotesCsvUnmarshallTest.Order order = (BindyDoubleQuotesCsvUnmarshallTest.Order)
map.values().iterator().next();
+        Order order = (Order) map.values().iterator().next();
         Assert.assertEquals(10, order.getOrderNr());
         Assert.assertEquals("Pauline", order.getFirstName());
         Assert.assertEquals("O'Donald", order.getLastName());
     }
 
     public static class ContextConfig extends RouteBuilder {
-        BindyCsvDataFormat camelDataFormat = new BindyCsvDataFormat("org.apache.camel.dataformat.bindy.csv");
+        BindyCsvDataFormat camelDataFormat = new BindyCsvDataFormat("org.apache.camel.dataformat.bindy.model.simple.oneclasssinglequote");
 
         public void configure() {
             from(URI_DIRECT_START).unmarshal(camelDataFormat).to(URI_MOCK_RESULT);

Copied: camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest.java
(from r1422568, camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindyInlinedQuotesCsvUnmarshallTest.java)
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest.java?p2=camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest.java&p1=camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindyInlinedQuotesCsvUnmarshallTest.java&r1=1422568&r2=1422751&rev=1422751&view=diff
==============================================================================
--- camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindyInlinedQuotesCsvUnmarshallTest.java
(original)
+++ camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest.java
Mon Dec 17 04:40:05 2012
@@ -24,6 +24,7 @@ import org.apache.camel.Produce;
 import org.apache.camel.ProducerTemplate;
 import org.apache.camel.builder.RouteBuilder;
 import org.apache.camel.component.mock.MockEndpoint;
+import org.apache.camel.dataformat.bindy.model.simple.oneclass.Order;
 import org.junit.Assert;
 import org.junit.Test;
 import org.springframework.test.annotation.DirtiesContext;
@@ -31,8 +32,8 @@ import org.springframework.test.context.
 import org.springframework.test.context.junit4.AbstractJUnit4SpringContextTests;
 
 @ContextConfiguration
-public class BindyInlinedQuotesCsvUnmarshallTest extends AbstractJUnit4SpringContextTests
{
-    
+public class BindySingleQuoteStartWordCsvUnmarshallTest extends AbstractJUnit4SpringContextTests
{
+
     private static final String URI_MOCK_RESULT = "mock:result";
     private static final String URI_DIRECT_START = "direct:start";
 
@@ -48,7 +49,7 @@ public class BindyInlinedQuotesCsvUnmars
     @DirtiesContext
     public void testUnMarshallMessage() throws Exception {
 
-        expected = "10,A9,'Pauline','O'Donald',ISIN,XD12345678,BUY,Share,2500.45,USD,08-01-2009";
+        expected = "10,A9,Patric,'T jo,ISIN,XD12345678,BUY,Share,2500.45,USD,08-01-2009";
 
         template.sendBody(expected);
 
@@ -56,19 +57,18 @@ public class BindyInlinedQuotesCsvUnmars
         result.assertIsSatisfied();
 
         Map<?, ?> map = (Map<?, ?>) result.getReceivedExchanges().get(0).getIn().getBody(List.class).get(0);
-        BindyDoubleQuotesCsvUnmarshallTest.Order order = (BindyDoubleQuotesCsvUnmarshallTest.Order)
map.values().iterator().next();
+        Order order = (Order) map.values().iterator().next();
         Assert.assertEquals(10, order.getOrderNr());
-        Assert.assertEquals("Pauline", order.getFirstName());
-        Assert.assertEquals("O'Donald", order.getLastName());
+        Assert.assertEquals("Patric", order.getFirstName());
+        Assert.assertEquals("'T jo", order.getLastName());
     }
 
     public static class ContextConfig extends RouteBuilder {
-        BindyCsvDataFormat camelDataFormat = new BindyCsvDataFormat("org.apache.camel.dataformat.bindy.csv");
+        BindyCsvDataFormat camelDataFormat = new BindyCsvDataFormat("org.apache.camel.dataformat.bindy.model.simple.oneclass");
 
         public void configure() {
             from(URI_DIRECT_START).unmarshal(camelDataFormat).to(URI_MOCK_RESULT);
         }
 
     }
-
 }

Modified: camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuotesCsvUnmarshallTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuotesCsvUnmarshallTest.java?rev=1422751&r1=1422750&r2=1422751&view=diff
==============================================================================
--- camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuotesCsvUnmarshallTest.java
(original)
+++ camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv/BindySingleQuotesCsvUnmarshallTest.java
Mon Dec 17 04:40:05 2012
@@ -53,12 +53,10 @@ public class BindySingleQuotesCsvUnmarsh
     }
 
     public static class ContextConfig extends RouteBuilder {
-        BindyCsvDataFormat camelDataFormat = new BindyCsvDataFormat("org.apache.camel.dataformat.bindy.csv");
+        BindyCsvDataFormat camelDataFormat = new BindyCsvDataFormat("org.apache.camel.dataformat.bindy.model.simple.oneclasssinglequote");
 
         public void configure() {
             from(URI_DIRECT_START).unmarshal(camelDataFormat).to(URI_MOCK_RESULT);
         }
-
     }
-
 }

Modified: camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/BindyUnmarshalCommaIssueTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/BindyUnmarshalCommaIssueTest.java?rev=1422751&r1=1422750&r2=1422751&view=diff
==============================================================================
--- camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/BindyUnmarshalCommaIssueTest.java
(original)
+++ camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/BindyUnmarshalCommaIssueTest.java
Mon Dec 17 04:40:05 2012
@@ -23,6 +23,7 @@ import org.apache.camel.builder.RouteBui
 import org.apache.camel.component.mock.MockEndpoint;
 import org.apache.camel.model.dataformat.BindyType;
 import org.apache.camel.test.junit4.CamelTestSupport;
+import org.junit.Ignore;
 import org.junit.Test;
 
 /**
@@ -85,6 +86,7 @@ public class BindyUnmarshalCommaIssueTes
     }
 
     @Test
+    //@Ignore
     public void testBindyUnmarshalSingleQuoteCommaIssueTwo() throws Exception {
         MockEndpoint mock = getMockEndpoint("mock:result");
         mock.expectedMessageCount(1);

Modified: camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/WeatherModel.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/WeatherModel.java?rev=1422751&r1=1422750&r2=1422751&view=diff
==============================================================================
--- camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/WeatherModel.java
(original)
+++ camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/csv2/WeatherModel.java
Mon Dec 17 04:40:05 2012
@@ -22,7 +22,7 @@ import org.apache.camel.dataformat.bindy
 /**
  *
  */
-@CsvRecord(separator = ",", quote = "\"")
+@CsvRecord(separator = ",", quote = "\"", quoting = true)
 public class WeatherModel {
 
     @DataField(pos = 1)

Added: camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/model/simple/oneclasssinglequote/Order.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/model/simple/oneclasssinglequote/Order.java?rev=1422751&view=auto
==============================================================================
--- camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/model/simple/oneclasssinglequote/Order.java
(added)
+++ camel/trunk/components/camel-bindy/src/test/java/org/apache/camel/dataformat/bindy/model/simple/oneclasssinglequote/Order.java
Mon Dec 17 04:40:05 2012
@@ -0,0 +1,156 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.dataformat.bindy.model.simple.oneclasssinglequote;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+import org.apache.camel.dataformat.bindy.annotation.CsvRecord;
+import org.apache.camel.dataformat.bindy.annotation.DataField;
+
+@CsvRecord(separator = ",", quote = "'")
+public class Order {
+
+    @DataField(pos = 1)
+    private int orderNr;
+
+    @DataField(pos = 2)
+    private String clientNr;
+
+    @DataField(pos = 3)
+    private String firstName;
+
+    @DataField(pos = 4)
+    private String lastName;
+
+    @DataField(pos = 5)
+    private String instrumentCode;
+
+    @DataField(pos = 6)
+    private String instrumentNumber;
+
+    @DataField(pos = 7)
+    private String orderType;
+
+    @DataField(name = "Name", pos = 8)
+    private String instrumentType;
+
+    @DataField(pos = 9, precision = 2)
+    private BigDecimal amount;
+
+    @DataField(pos = 10)
+    private String currency;
+
+    @DataField(pos = 11, pattern = "dd-MM-yyyy")
+    private Date orderDate;
+
+    public int getOrderNr() {
+        return orderNr;
+    }
+
+    public void setOrderNr(int orderNr) {
+        this.orderNr = orderNr;
+    }
+
+    public String getClientNr() {
+        return clientNr;
+    }
+
+    public void setClientNr(String clientNr) {
+        this.clientNr = clientNr;
+    }
+
+    public String getFirstName() {
+        return firstName;
+    }
+
+    public void setFirstName(String firstName) {
+        this.firstName = firstName;
+    }
+
+    public String getLastName() {
+        return lastName;
+    }
+
+    public void setLastName(String lastName) {
+        this.lastName = lastName;
+    }
+
+    public String getInstrumentCode() {
+        return instrumentCode;
+    }
+
+    public void setInstrumentCode(String instrumentCode) {
+        this.instrumentCode = instrumentCode;
+    }
+
+    public String getInstrumentNumber() {
+        return instrumentNumber;
+    }
+
+    public void setInstrumentNumber(String instrumentNumber) {
+        this.instrumentNumber = instrumentNumber;
+    }
+
+    public String getOrderType() {
+        return orderType;
+    }
+
+    public void setOrderType(String orderType) {
+        this.orderType = orderType;
+    }
+
+    public String getInstrumentType() {
+        return instrumentType;
+    }
+
+    public void setInstrumentType(String instrumentType) {
+        this.instrumentType = instrumentType;
+    }
+
+    public BigDecimal getAmount() {
+        return amount;
+    }
+
+    public void setAmount(BigDecimal amount) {
+        this.amount = amount;
+    }
+
+    public String getCurrency() {
+        return currency;
+    }
+
+    public void setCurrency(String currency) {
+        this.currency = currency;
+    }
+
+    public Date getOrderDate() {
+        return orderDate;
+    }
+
+    public void setOrderDate(Date orderDate) {
+        this.orderDate = orderDate;
+    }
+
+    @Override
+    public String toString() {
+        return "Model : " + Order.class.getName() + " : " + this.orderNr + ", " + this.orderType
+ ", " + String.valueOf(this.amount) + ", " + this.instrumentCode + ", "
+                + this.instrumentNumber + ", " + this.instrumentType + ", " + this.currency
+ ", " + this.clientNr + ", " + this.firstName + ", " + this.lastName + ", "
+                + String.valueOf(this.orderDate);
+    }
+}
+

Added: camel/trunk/components/camel-bindy/src/test/resources/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest-context.xml
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/test/resources/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest-context.xml?rev=1422751&view=auto
==============================================================================
--- camel/trunk/components/camel-bindy/src/test/resources/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest-context.xml
(added)
+++ camel/trunk/components/camel-bindy/src/test/resources/org/apache/camel/dataformat/bindy/csv/BindySingleQuoteStartWordCsvUnmarshallTest-context.xml
Mon Dec 17 04:40:05 2012
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+<beans xmlns="http://www.springframework.org/schema/beans"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="
+     http://www.springframework.org/schema/beans
+     http://www.springframework.org/schema/beans/spring-beans.xsd
+     http://camel.apache.org/schema/spring
+     http://camel.apache.org/schema/spring/camel-spring.xsd">
+     
+	<camelContext xmlns="http://camel.apache.org/schema/spring">
+		<routeBuilder ref="myBuilder" /> 
+	</camelContext>
+	
+	<bean id="myBuilder" class="org.apache.camel.dataformat.bindy.csv.BindySingleQuoteStartWordCsvUnmarshallTest$ContextConfig"/>
+	
+</beans>
\ No newline at end of file



Mime
View raw message