[
https://issues.apache.org/jira/browse/HTTPCORE-297?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13254938#comment-13254938
]
Gary D. Gregory commented on HTTPCORE-297:
------------------------------------------
I am attaching two patches:
- a "simple" patch that adds one API to StringEntity: StringEntity(String,
Charset)
- a "more" patch that pushes the Charset change down to the ContentType.
Issues with the "more" patch:
- This is an experiment that might be to late for 4.2, this causes one unit
test to fail at
org.apache.http.impl.io.TestSessionBuffers.testUnmappableInputAction(TestSessionBuffers.java:549)
- This changes what the ContentType getCharset will return: when you give it a
non-cannonical charset name, this name will be used to get the Charset from the
cache and then return the cannonical name.
> Add StringEntity APIs that use Charset instead of chaset name Strings
> ---------------------------------------------------------------------
>
> Key: HTTPCORE-297
> URL: https://issues.apache.org/jira/browse/HTTPCORE-297
> Project: HttpComponents HttpCore
> Issue Type: Improvement
> Affects Versions: 4.1.2
> Environment: Apache Maven 3.0.4 (r1232337; 2012-01-17 03:44:56-0500)
> Maven home: C:\Java\apache-maven-3.0.4\bin\..
> Java version: 1.6.0_31, vendor: Sun Microsystems Inc.
> Java home: C:\Program Files\Java\jdk1.6.0_31\jre
> Default locale: en_US, platform encoding: Cp1252
> OS name: "windows 7", version: "6.1", arch: "amd64", family: "windows"
> Reporter: Gary D. Gregory
> Attachments: httpcore-297-more.diff, httpcore-297-simple.diff
>
>
> Add:
> - org.apache.http.entity.StringEntity.StringEntity(String, Charset)
> - org.apache.http.entity.StringEntity.StringEntity(String, String, Charset)
> To match the existing:
> - org.apache.http.entity.StringEntity.StringEntity(String, String)
> - org.apache.http.entity.StringEntity.StringEntity(String, String, String)
> Same idea for:
> - org.apache.http.nio.entity.NStringEntity
> - org.apache.http.nio.entity.StringNIOEntity
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]