On Sat, Oct 06, 2012 at 11:44:02AM -0700, Ethan Furman
Oleg Broytman wrote:
IMO there is no need to replace parts beyond drive/name/extension. To "replace" root or path components just construct a new Path.
And if your new path is exactly the same as the old, /except/ for the root? Are you suggesting something like:
--> p = PureNTPath('c:/orders/12345/abc67890.dbf') --> q = '//another_machine/share' + p.parts() + p.filename
?
Yes. Even if the new path differs from the old by one letter somewhere in a middle component. "Practicality beats purity". We need to see real use cases to decide what is really needed. Oleg. -- Oleg Broytman http://phdru.name/ phd@phdru.name Programmers don't die, they just GOSUB without RETURN.