Article View: borland.public.jbuilder.java.language
Article #15112Re: File properties
From: Steve Horsley
Date: Fri, 09 Jul 1999 00:00
Date: Fri, 09 Jul 1999 00:00
17 lines
988 bytes
988 bytes
Try:
import java.io.File;
File f = new File("mydata.dat");
if(f.canRead())
System.out.println("I can read it");
if(f.canWrite())
System.out.println("I can write it");
There's no mention of the archived flag - I guess it's not portable,
so it's not supported.
Steve.
//-------------------------
Jonathan wrote:
>
> How do you get file properties for a file e.g. whether it has been archived,
> read only etc.....
Technical Details
Message-ID:
<3785BE0B.C4068E3A@cwcom.co.uk>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<7m1s6k$gvg9@forums.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f74b3,2361946dfd3f0a62 X-Google-Attributes: gidf74b3,public From: Steve Horsley <steve.horsley@cwcom.co.uk> Subject: Re: File properties Date: 1999/07/09 Message-ID: <3785BE0B.C4068E3A@cwcom.co.uk> X-Deja-AN: 499030540 Content-Transfer-Encoding: 7bit References: <7m1s6k$gvg9@forums.borland.com> X-Accept-Language: en Content-Type: text/plain; charset=us-ascii Organization: Cable & Wireless Communications Mime-Version: 1.0 Newsgroups: borland.public.jbuilder.java.language