You will need to be completely familiar with the RandomAccessFile class in order to read and write to specific locations in the disk file. I strongly recommend that you read up on this class before starting on this assignment. In particular, you'll need to understand how to use the seek method to move the file pointer to a specific location in the file and then you can read/write at that location.
Once you understand how seek works, all you need to do is compute the byte offset of the object you are tying to access and seek to that location before reading or writing. Remember to count from 0 (not 1)!!
Your file system can support a maximum file size of 8 blocks (8KB). That does NOT mean that every file will be 8KB in size. In most cases, files will be smaller than the max file size. Each "create" request should check whether the disk has sufficient space for the file and if not, return a "not enough space on disk" error message.
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.
Most file operations will only touch the superblock (the free block list and the inode). However, the read and write calls need you to actually read and write data from the specified block on disk. In case of write, you can use a dummy buffer (e.g., with all 1s) to write to disk. Remember, what you write out is what should get read in if you use "read" at a later time.
There are a couple of ways to do this. The RandomAccessFile class provides a readInt and writeInt methods to write out 32 bit representations of integers (Thanks to some of you for pointing this out.) Similarly, readByte and writeByte allow you to read/write 1 byte characters (note: readChar and writeChar write out 2 bytes not 1. Since we have allocated only one byte per character on disk it is best not to use these methods).
The other way to do this is to first convert all fields of the inode into characters (total of 48 bytes per inode) , and then write out these 48 bytes to disk. To do this, you will need to convert integers into their 32-bit (4 byte) representation while writing them out, and vice versa after reading them in. Here is sample code that implements the int2char() and char2int() methods to do this (you'll need to modify the sample code a bit to return a 4 character array in int2char(), and to return an integer in char2int()).
Since the functionality provided by readInt and writeInt methods of the RandomAccessFile class is adequate, I strongly recommend the former method over the latter.