public int findIndexOfFileDescriptor(String filename, boolean delete) throws Exception {
			for(int i = 0; i < 3; i++){
				
				if(oft.readDiskToBuffer(0, i) == -1)
					throw new Exception("Block not assigned");
				
				byte[] memory = oft.getBuffer(0);
				for(int j = 0; j < memory.length; j = j + DIRECTORY_ENTRY_SIZE_IN_BYTES){
					boolean foundMatch = true;
					for(int k = 0; k < filename.length(); k++){
						if(((char) memory[j + k]) != (byte) filename.charAt(k))
							foundMatch = false;
					}
					if(foundMatch){
						int returnValue = unpack(memory, j + SIZE_OF_INT_IN_BYTES);
						if(delete) {
							for(int m = 0; m < 8; m++){
								memory[j + m] = -1;
								oft.writeByteArray(0, 0, memory);
							}
						}
						return returnValue; //Return the 4th element, or the file descriptor index
					}
				}
			}
			throw new Exception("Could not find file descriptor index for a file that SHOULD exist");
	}