-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
External DTD Encoding with EXIficient #46
Comments
When you encoded the exi file, did you set the -includeOptions option to save the encoding options you used, so that the decoder would use the same options? Or, alternatively, did you explicitly provide those options (-preserveDTDs, etc) to the decode command? |
FYI: EXIficient was part of the EXI implementation report. Hence, all features are implemented. By default, most XML artifacts like comments, prefixes, DTDs etc. are not preserved (to get the best compression). Anyhow, as mentioned in this thread, you need to set encoding options (when encoding the file) if you need them. see https://github.com/EXIficient/exificient?tab=readme-ov-file#command-line-interface for the command-line interface. |
Here is what I'm doing exactly, with the outputs. I am not able to successfully persist the external reference.
|
I looked into, and it seems the handler misses one call (it does not handle it, it is just empty while the other methods are implemented) exificient/src/main/java/com/siemens/ct/exi/main/api/sax/SAXEncoderExtendedHandler.java Lines 286 to 288 in e7c2f00
I will try to fix that |
I created #47 Please have a look and report back @brandonprry |
That almost does it,but I don't see the external entity being persisted after decoding. Here is the XML after decoding from EXI with the exact command as pasted above.
Here is the original XML, with the entity reference in element which is missing after decoding. However, the ENTITY is persisted correctly.
|
I checked the EXI file which contains the text Not sure... entity references are a bit special and my knowledge faded .. exificient/src/main/java/com/siemens/ct/exi/main/api/sax/SAXDecoder.java Lines 642 to 645 in e7c2f00
|
I will dig. |
I've tried several EXI implementations. OpenV2G, RISE-V2G, and some others. I've not found one yet that supports external entities. This may just be squirrelly feature that hasn't been useful for applications consuming EXI yet. I'll leave this open, it's not a pertinent feature for me at the moment, but it will be. I should still be able to dig and find out what code should be fixed to make this work. |
I've read that EXI encoding should support encoding an external DTD reference. For instance.
I've attempted to encode this with the CMD class, but I cannot seem to encode it properly so that decoding preserves the external DTD reference, even with the -preserveDTDs -preservePIs etc arguments.
Can EXIficient encode an external DTD reference that will be decoded still as an external reference to a fragment?
Thanks so much.
The text was updated successfully, but these errors were encountered: