[
https://issues.apache.org/jira/browse/CODEC-121?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14198632#comment-14198632
]
Gary Gregory edited comment on CODEC-121 at 11/5/14 4:50 PM:
-------------------------------------------------------------
I am wondering if the strict boolean should be an enum instead in order to
allow for other settings in the future and more clarity. Booleans can be
cryptic, so even if there are no other settings later, the code might look
better with a {{Policy.STRICT}} and {{Policy.LENIENT}} in the code instead of
{{true}} and {{false}}. Feel free to come up with a better name than {{Policy}}.
Thoughts?
Gary
was (Author: garydgregory):
I am wondering if the strict boolean should be an enum instead in order to
allow for other settings in the future and more clarity. Booleans can be
cryptic, so even if there are no other settings later, the code might look
better with a {{Policy.STRICT}} and {{Policy.LENIENT}} in the code instead of
true and false. Feel free to come up with a better name than {{Policy}}
Thoughts?
Gary
> QuotedPrintableCodec does not support soft line break per the
> 'quoted-printable' example on Wikipedia
> -----------------------------------------------------------------------------------------------------
>
> Key: CODEC-121
> URL: https://issues.apache.org/jira/browse/CODEC-121
> Project: Commons Codec
> Issue Type: Bug
> Affects Versions: 1.5, 1.6
> Environment: I tested on Windows 7.
> Reporter: Java John
> Labels: codec, decode, quoted-printable
> Fix For: 2.0
>
> Attachments: CODEC-121_postponed.patch, CODEC-121_v2.patch
>
>
> Writing a unit test I discovered that the example Wikipedia uses for
> quoted-printable data does not decode but instead throws an exception.
> Their example is here: http://en.wikipedia.org/wiki/Quoted-printable#Example
> test:
> String qpdata = "If you believe that truth=3Dbeauty, then surely=20=\r\n"
> +
> "mathematics is the most beautiful branch of philosophy.";
> String expected = "If you believe that truth=beauty, then surely " +
> "mathematics is the most beautiful branch of philosophy.";
> assertEquals( expected, new QuotedPrintableCodec().decode(qpdata) );
> I suppose I could fix if you like but currently I'm not a registered
> developer.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)