Java write byte in file
<p>I am doing in Java a File Comprimir to a Binary File. The problem is the next, how can I write a Byte in a new File that the total size only occups 1 byte? I am doing the next:</p>

<pre><code>FileOutputStream saveFile=new FileOutputStream("SaveObj3.sav");
        // Create an ObjectOutputStream to put objects into save file.
        ObjectOutputStream save = new ObjectOutputStream(saveFile);

        save.writeByte(0);


        save.close();
        saveFile.close();
</code></pre>

<p>That, only must to write a only byte in the file, but when I look the size,it occups 7 bytes. Anyone knows how can I write a only byte? Is there another way better?</p>
