The layering feature is not extensible the way you need it to be. Our hope is to make it pluggable so that you could write a tiny java class and plug it in and introduce new layering transforms easily. Alas, we don't have that feature yet.
The layering feature is also not entirely baked yet. For example we'd like to be able to use it to compute/verify parity and/or checksums over parts of the data, but we don't have that figured out yet. One of the beauties of open source software is that one can add the layer transform that you need. If what you need is really a variation on one we have that would be pretty easy to do. If you are a Java developer you can probably pull this off. Either way we'll create a JIRA ticket to add this feature so that if you can't do this someone else may be able to quickly do it for you. In terms of using Daffodil 2.6.0 today to solve your issue, I think a preprocessor to just convert all the folded lines to the type we already have a transform for, (which I think require CRLFs?) perhaps is just standardizing line endings to CRLF? If so existing preprocessor tools for converting files from Unix conventions (LF only) to MS-Windows (CRLF) style might solve your problem. ________________________________ From: Depth Painter <depth.pain...@mail.com> Sent: Wednesday, April 29, 2020 1:08 PM To: users@daffodil.apache.org <users@daffodil.apache.org> Subject: DFDL Layers Hello, I'm currently trying to make a dfdl schema for a textual file format. While I have mostly finished, there are two things that are currently giving me difficulty: Line folding and line comments. For line folding the layer transforms specifically the lineFolded_* family looks promising however the two that are implemented don't match my file specification because crlf%x20; and lf%x20; can both be used to fold lines. As for line comments I currently have some Comment elements peppered throughout my schema however I'm sure I missed some. And that strategy isn't even up to spec because comments are supposed to be ignored during parsing. Other then preprocessing the file do you guys have any recommendations to handle these issues I'm facing? Thanks DP