🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.api
Article #2154

File.renameTo() doesn't update object

#2154
From: Owen Green
Date: Thu, 03 May 2001 11:27
12 lines
1239 bytes
or so it seems....

When I call File.renameTo(), the file is indeed renamed on disk , but the
object still returns the same values as before for getAbsaloutePath() etc.
Does this mean that I should be retaining a reference to the file object I
passed with the new file name?

Is this behaviour docmented anywhere, and moreover, why does it behave this
way??

TIA
Owen
Technical Details
Message-ID: <3af1409d$1_2@dnews>
Path: arc1-ca.pugleaf.net!newsfeed.google.com!sn-xit-02!supernews.com!news.tele.dk!193.251.151.101!opentransit.net!newsfeeds.belnet.be!news.belnet.be!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!dnews

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 1089d0,a7b3eb68e6cc2342,start
X-Google-Attributes: gid1089d0,public
X-Google-ArrivalTime: 2001-05-03 04:45:02 PST
From: "Owen Green" <owen@norobots.unique.com>
Newsgroups: borland.public.jbuilder.java.api
Subject: File.renameTo() doesn't update object
Date: Thu, 3 May 2001 12:27:22 +0100
Lines: 14
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.50.4133.2400
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400
NNTP-Posting-Host: 213.86.7.136
Message-ID: <3af1409d$1_2@dnews>
X-Trace: dnews 988889245 213.86.7.136 (3 May 2001 04:27:25 -0700)
Path: arc1-ca.pugleaf.net!newsfeed.google.com!sn-xit-02!supernews.com!news.tele.dk!193.251.151.101!opentransit.net!newsfeeds.belnet.be!news.belnet.be!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!dnews