Java Solaris Communities Sun Store Join SDN My Profile Why Join?
 
Bug Database
Bug Detail
Quick Lists
Top 25 Bugs
Top 25 RFE's
Recently Closed Bugs
Printable Page Printable Page


Bug Database
Bug ID: 6717791
Votes 0
Synopsis File static factory to consistently/correctly handle absolute or drive-relative paths
Category java:classes_io
Reported Against
Release Fixed
State 11-Closed, duplicate of 4313887, request for enhancement
Priority: 5-Very Low
Related Bugs
Submit Date 23-JUN-2008
Description
A DESCRIPTION OF THE REQUEST :
  Bugs such as 4418831 and 4242635 show that java.io.File(File, String) and (String, String) don't behave consistently with expectation when the second argument is an absolute or drive-relative (in Windows) path. A new method should therefore be created that deals with these situations in a consistent way and avoids the need for developer's to jump through hoops in order to get simple path joining capabilities (viz-a-viz Python's os.path.join(.) function).

Or you could just fix the dodgy constructors...

JUSTIFICATION :
  To make Java better. Less hair loss over inane behaviour is always a  customer  thing.
Posted Date : 2008-06-23 11:09:27.0
Work Around
N/A
Evaluation
The new file system API (being defined by JSR-203) defines resolve and relativize methods. On Windows it understands each of the 5 different path types and how to combine them.
Posted Date : 2008-06-23 20:41:14.0
Comments
  
  Include a link with my name & email   


PLEASE NOTE: JDK6 is formerly known as Project Mustang