src/Bunny/Protocol/ProtocolWriter.php
public function appendBits(array $bits, Buffer $buffer)
    {
        $value = 0;
        foreach ($bits as $n => $bit) {
            $bit = $bit ? 1 : 0;
            $value |= $bit << $n;
        }
        $buffer->appendUint8($value);
    }
public function appendBits(array $bits, Buffer $buffer)
    {
        $value = 0;
        foreach ($bits as $n => $bit) {
            $bit = $bit ? 1 : 0;
            $value |= $bit << $n;
        }
        $buffer->appendUint8($value);
    }
public function appendBits ( array $ bits , Buffer $ buffer ) { $ value = 0 ; foreach ( $ bits as $ n => $ bit ) { $ bit = $ bit ? 1 : 0 ; $ value |= $ bit << $ n ; } $ buffer -> appendUint8 ( $ value ) ; }
Appends packed bits to buffer.

@param array $bits
@param Buffer $buffer
Appends packed bits to buffer .