Can I use Java data types such as Strings to represent file names instead of character arrays?
Feel free to do so in your file system program. HOWEVER, you should be very careful in what get written out to the disk. Since each inode has space allocated for exactly 8 bytes to hold the file name, you should always write out 8 characters to disk, regardless of the file size. If your file name is shorter, the unused characters should have the ‘\0’ or spaces. Thus, if you use strings, you’ll need to make sure exactly 8 characters are written out, regardless of the string length. I recommend that you use character arrays instead of strings if possible.