JDK-4146652 : java.net.URLEncoder.java needs to support more forms of encode method
  • Type: Enhancement
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 1.2.0
  • Priority: P5
  • Status: Closed
  • Resolution: Duplicate
  • OS: generic
  • CPU: generic
  • Submitted: 1998-06-08
  • Updated: 2000-04-24
  • Resolved: 2000-04-24
Related Reports
Duplicate :  
Relates :  
Relates :  
Description
Currently in both JDK1.1.x and JDK1.2, URLEncoder only has one method URLEncode.encode(String data) which encodes the data by using default charater encoding type set by system property "file.encoding". However there are cases a browser needs to handle more than one encoding types at same time, so supporting more forms of encode method is necessary.

Request to add encode(String data, String charEncType) method.

[above by original submitter]

Note that this supports the convention that's been pushed by Netscape:

 http://people.netscape.com/ftang/paper/unicode11paper/t005.html

as well as the more recent (March 1998) approach presented at the IETF:

 ftp://ietf.org/internet-drafts/draft-masinter-url-i18n-01.txt

Both require encoding into bytes, then URL-encoding.

NOTE that whatever solution is adopted should be mirrored in the
new java.net.URLDecoder class too. 
 
david.brownell@Eng 1998-07-06

Comments
SUGGESTED FIX The justification says, not enough resource. How about that we have the code in hand already, and Dave Brownell has or will not mind to review it (I think) and we will put it back into the workspace. What needs to be done is regression test, but it's very unlikely it will cause any regression bug. mma
11-06-2004

EVALUATION mayank.upadhyay@eng 2000-04-24 See eval for 4257115
24-04-2000