public function processResponse()
    {
        // Holds the processed packets so we can sort them in case they come in an unordered
        $processed = [];

        // Iterate over the packets
        foreach ($this->packets_response as $response) {
            // Check to see if we had a preg_match error
            if (($match = preg_match("#^(.*)\\\\queryid\\\\([^\\\\]+)(\\\\|$)#", $response, $matches)) === false
                || $match != 1
            ) {
                throw new Exception(__METHOD__ . " An error occurred while parsing the packets for 'queryid'");
            }

            // Multiply so we move the decimal point out of the way, if there is one
            $key = (int)(floatval($matches[2]) * 1000);

            // Add this packet to the processed
            $processed[$key] = $matches[1];
        }

        // Sort the new array to make sure the keys (query ids) are in the proper order
        ksort($processed, SORT_NUMERIC);

        // Create buffer and offload processing
        return $this->processStatus(new Buffer(implode('', $processed)));
    }
public function processResponse()
    {
        // Holds the processed packets so we can sort them in case they come in an unordered
        $processed = [];

        // Iterate over the packets
        foreach ($this->packets_response as $response) {
            // Check to see if we had a preg_match error
            if (($match = preg_match("#^(.*)\\\\queryid\\\\([^\\\\]+)(\\\\|$)#", $response, $matches)) === false
                || $match != 1
            ) {
                throw new Exception(__METHOD__ . " An error occurred while parsing the packets for 'queryid'");
            }

            // Multiply so we move the decimal point out of the way, if there is one
            $key = (int)(floatval($matches[2]) * 1000);

            // Add this packet to the processed
            $processed[$key] = $matches[1];
        }

        // Sort the new array to make sure the keys (query ids) are in the proper order
        ksort($processed, SORT_NUMERIC);

        // Create buffer and offload processing
        return $this->processStatus(new Buffer(implode('', $processed)));
    }
public function processResponse ( ) { // Holds the processed packets so we can sort them in case they come in an unordered $ processed = [ ] ; // Iterate over the packets foreach ( $ this -> packets_response as $ response ) { // Check to see if we had a preg_match error if ( ( $ match = preg_match ( "#^(.*)\\\\queryid\\\\([^\\\\]+)(\\\\|$)#" , $ response , $ matches ) ) === false || $ match != 1 ) { throw new Exception ( __METHOD__ . " An error occurred while parsing the packets for 'queryid'" ) ; } // Multiply so we move the decimal point out of the way, if there is one $ key = ( int ) ( floatval ( $ matches [ 2 ] ) * 1000 ) ; // Add this packet to the processed $ processed [ $ key ] = $ matches [ 1 ] ; } // Sort the new array to make sure the keys (query ids) are in the proper order ksort ( $ processed , SORT_NUMERIC ) ; // Create buffer and offload processing return $ this -> processStatus ( new Buffer ( implode ( '' , $ processed ) ) ) ; }
Process the response for this protocol

@return array
@throws Exception
Process the response for this protocol