     }
     
     ///process the finished response of a buffer
-    func processResponse(response: WSResponse) -> Bool {
+    private func processResponse(response: WSResponse) -> Bool {
         if response.isFin && response.bytesLeft <= 0 {
             if response.code == .Ping {
                 let data = response.buffer! //local copy so it is perverse for writing

        self.initStreamsWithData(serializedRequest,port!)
    }
    //Add a header to the CFHTTPMessage by using the NSString bridges to CFString
    func addHeader(urlRequest: Unmanaged<CFHTTPMessage>,key: String, val: String) {
        let nsKey: NSString = key
        let nsVal: NSString = val
        CFHTTPMessageSetHeaderFieldValue(urlRequest.takeUnretainedValue(),

    }
    
    ///process the websocket data
    private func processRawMessage(buffer: UnsafePointer<UInt8>, bufferLen: Int) {
        var response = _readStack.last
        if response != nil && bufferLen < 2 {
            _fragBuffer = NSData(bytes: buffer, length: bufferLen)
