[ https://issues.apache.org/jira/browse/CAMEL-10840?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15870604#comment-15870604 ]
Christian Ribeaud commented on CAMEL-10840: ------------------------------------------- Good evening [~davsclaus]. I asked because of history. Currently, we only see _Unassigned_. I do not care being able to _self-assign_. But, later on, you might want to know who tackled this issue. I am pretty sure you can assign the issue, are not you? In my opinion, making the {{CsvRecordConverters}} _public_ is not a good idea. This class is used to an internal purpose and is pretty small. No big logic worth of making _public_ here. Making {{CsvRecordConverter}} is a good idea. However, because of the reason I mentioned (I would like to proxy the invocation {{record.get\(i))}} rsp. {{values\[i]}}), I am not sure which way I should go: * Via *Java* reflection, I am accessing _mapping_ of {{CSVRecord}}. The API of {{CSVRecord}} is quite limited indeed. It is strange that, for instance, there is no possibility to access the mapping keys from {{CSVRecord}} itself, although the information is available. This would be needed for {{MapCsvRecordConverter}} implementation. * I am allowed to add a dependency to some useful library like [Commons Collections|https://commons.apache.org/proper/commons-collections/]. What are the policies regarding external dependencies? * I am just making {{CsvRecordConverter}} _public_. Callers should then adapt the returned results to their needs, even if they should go over a whole collection or map. > CsvDataFormat.setRecordConverterRef not usable > ---------------------------------------------- > > Key: CAMEL-10840 > URL: https://issues.apache.org/jira/browse/CAMEL-10840 > Project: Camel > Issue Type: Improvement > Components: camel-csv > Affects Versions: 2.18.1 > Reporter: Christian Ribeaud > Priority: Minor > Fix For: 2.18.3, 2.19.0 > > > Following interface {{org.apache.camel.dataformat.csv.CsvRecordConverter}} is > *package* protected. This is actually fine because it is used internally. > There are two implementations in {{CsvRecordConverters}}. However > {{org.apache.camel.model.dataformat.CsvDataFormat}} contains following > *public* methods: > {code:java} > public String getRecordConverterRef() { > return recordConverterRef; > } > /** > * Refers to a custom <tt>CsvRecordConverter</tt> to lookup from the registry > to use. > */ > public void setRecordConverterRef(String recordConverterRef) { > this.recordConverterRef = recordConverterRef; > } > {code} > So, it seems possible to specify my own {{CsvRecordConverter}} but, because > of the point mentioned earlier, this is actually NOT (easily) possible. > I came across this point because I was looking for a mechanism allowing me to > proxy the values being taken from {{CSVRecord}} to *Map* or *List*. -- This message was sent by Atlassian JIRA (v6.3.15#6346)