This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Currently it seems impossible to partially encode/decode using the customencoder-1.0. Example: <Container> <Payload> John Doe;Engineer;30 Ola Nordmann;Manager;35 </Payload> <MetaData>someData</MetaData> </Container> mapping to <Container> <Payload> <Employees> <Employee> <Name>John Doe</Name> <Role>Engineer</Role> <Age>30</Age> <Employee> <Employee> <Name>Ola Nordmann</Name> <Role>Manager</Role> <Age>35</Age> <Employee> </Payload> <MetaData>someData</MetaData> </Container> A current workaround would be to create another CA that does nothing but encoding or decoding and transfer the flat file to/from that CA over file or JMS. However if the bpel mapper had encode and decode functions (probably organized in the Node category), this would be easy to achieve. It would be a more flexible solution than adding the ability to partially encode/decode to the customencoder-1.0, since you then would have to add BCs just for the sake of encoding/decoding.
Will look into this.
I agree, the shortage of functions is a real problem in XPath 1.0. :-( For example, I can't find a function which is analog of the Java's String.indexOf() I believe the XPath 2.0 has much more sophisticated functions. So it would be possible to do such simple encoding or decoding with sequence of XPath functions' calls. But it isn't useful anyway because it requires repeating declaring the same sequence each time it's necessary to do the same piece of job. Unfortunately BPEL doesn't support declaring new XPath functions. But fortunately it doesn't prohibit it as well. BPEL allows writing expressions not only with the XPath. The XPath 1.0 is considered as the default expression language. So I think any extensions can be suggested in case we use a language other then XPath (Java, for example) or at least the XPath with some extensions. But I think we should assign the expressionLanguage (queryLanguage) attribute to inform runtime about extensions.
I think the issue #152020 is related
From an implementation point of view issue #152020 may very well be related. Still I believe that the custom encoder editor is very good once you learn it. From a user perspective it would be nice to be able to use that same tool to partially encode/decode using the customencoder-1.0.