protected function processMessageFrame(WebSocketFrame $frame)
    {
        if ($this->_openMessage && $this->_openMessage->isFinalised() == false) {
            $this->_openMessage->takeFrame($frame);
        } else {
            $this->_openMessage = WebSocketMessage::fromFrame($frame);
        }

        if ($this->_openMessage && $this->_openMessage->isFinalised()) {
            $this->emit("message", array('message' => $this->_openMessage));
            $this->_openMessage = null;
        }
    }