private void writeBit(int bit) throws IOException
    {
        if (bit == 0) 
            this.bits <<= 1;
        else
            this.bits = this.bits << 1|1;
        
        this.offSet++;
        
        if (this.offSet == 8) {
            this.ecrire.write(this.bits);
            this.bits = 0;
            this.offSet = 0;
        }
    }