Win a copy of Java 9 Revealed this week in the Features new in Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

some facts about file properties in Windows OS  RSS feed

 
K. Tsang
Bartender
Posts: 3639
16
Firefox Browser Java Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all, I was experimenting with file properties on Windows OS to see when I would get IOException when loading the data file. Here is what I noted:

if directory is set to
* read-only => run ok
* hidden => run ok
* deny any permission => FileNotFoundException

if file is set to
* read-only => FileNotFoundException
* hidden => run ok
* deny any permission => FileNotFoundException

By the way I'm using RandomAccessFile to read/write data.

Oh also if running in network mode, if the server is started then you change the file properties, the network client will run fine using the old established settings/properties. If you restart the server you get FileNotFoundException

Hope this helps.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!