Code example for RandomAccessFile

Methods: writeByte

0
        } 
    } 
 
    public void putc(byte b) throws IOException {
        try { 
            raf.writeByte(b);
        } catch (IOException e) {
            PortableFileSystem.processIOException(e);
        } 
    } 
 
    public byte getc() throws IOException { 
        try { 
            return raf.readByte();
        } catch (IOException e) {
            PortableFileSystem.processIOException(e);
            throw e; //unreachable
        } 
    } 
 
    public byte[] read(int n) throws IOException {