camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian Mueller (JIRA)" <j...@apache.org>
Subject [jira] Commented: (CAMEL-2731) Camel-bindy should be able to process fix length records
Date Wed, 26 May 2010 20:36:52 GMT

    [ https://issues.apache.org/activemq/browse/CAMEL-2731?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=59552#action_59552
] 

Christian Mueller commented on CAMEL-2731:
------------------------------------------

Hello Claus, hello Charles,

after a short discussion yesterday with Claus about another topic, I had a look on [Smooks|http://www.smooks.org/].
It looks for me, that Smooks already solved this problem: [Smooks fixed length to java example|http://svn.codehaus.org/milyn/tags/Smooks_V1.3/smooks-examples/fixed-length-to-java/].
Would you like that I extend the Camel Bindy component or/and the Camel Smooks component?
IMO, its easier for the users if they only have one solution which fits there needs and not
multiple components, even Camel Bindy (annotations) and Camel Smooks (Java or XML configuration)
will solve this issue in different ways...

Thanks for your help,
Christian


> Camel-bindy should be able to process fix length records
> --------------------------------------------------------
>
>                 Key: CAMEL-2731
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-2731
>             Project: Apache Camel
>          Issue Type: Improvement
>          Components: camel-bindy
>    Affects Versions: 2.3.0
>         Environment: All
>            Reporter: Christian Mueller
>            Assignee: Christian Mueller
>             Fix For: 2.4.0
>
>
> Camel-bindy should be able to process fix length records which has no separators:
> A sample line could looks like: 
> {code}
> 4711123456789065432109876543219999999999999999
> {code}
> 4711 is the companyId
> 1234567890 is the cardProgram
> 6543210987654321 is the accountNumber
> 9999999999999999 is the cardNumber
> Created a POJO with the Camel bindy annotations:
> {code}
> @CsvRecord(separator = "")
> public class CSVRecord implements Serializable {
>        
>     @DataField(pos = 1, length = 4)
>     private String companyId;
>        
>     @DataField(pos = 2, length = 10)
>     private String cardProgram;
>     @DataField(pos = 3, length = 16)
>     private String accountNumber;
>        
>     @DataField(pos = 4, length = 16)
>     private String cardNumber;
>    // getter and setter
> }
> {code} 
> See [nabble|http://old.nabble.com/camel-bindy%3A-not-possible-to-process-fix-length-records-without-separators--ts28584909.html]
for details.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message