- marked as trivial
Standardize HTML/XML encoders/decoders and remove hand-crafted HTML/XML encoding/decoding code
Issue #818
new
okapi/core/src/main/java/net/sf/okapi/common/encode/HtmlEncoder.java, okapi/core/src/main/java/net/sf/okapi/common/encoder/XMLEncoder.java and probably more include the encoders and decoders to convert the XML and/or HTML entities and characters. But since there are the standard encoding/decoding, there are open source solutions for this, including Apache Commons Text (StringEscapeUtil package) and ubescape.org’s library. We should pick a library and use it, rather than having our own implementations that could get outdated.
The subfiltering step (a new step in the pending pull request #300) uses both ubescape.org and Apache Commons Text. They should be modified to use the one that is selected.
Comments (1)
-
reporter - Log in to comment
okapi/core/src/main/java/net/sf/okapi/common/encode/HtmlEncoder.java, okapi/core/src/main/java/net/sf/okapi/common/encoder/XMLEncoder.java and probably more include the encoders and decoders to convert the XML and/or HTML entities and characters. But since there are the standard encoding/decoding, there are open source solutions for this, including Apache Commons Text (StringEscapeUtil package) and ubescape.org’s library. We should pick a library and use it, rather than having our own implementations that could get outdated.
The subfiltering step (a new step in the pending pull request #300) uses both ubescape.org and Apache Commons Text. They should be modified to use the one that is selected.