Kraken\Util\Buffer\Buffer::pop PHP Method

pop() public method

public pop ( $length )
    public function pop($length)
    {
        $length = (int) $length;
        if (0 >= $length) {
            return '';
        }
        $buffer = (string) substr($this->data, -$length);
        $this->data = (string) substr($this->data, 0, -$length);
        return $buffer;
    }