Browse Source

Get ResponseReader options values.

Daniele Alessandri 15 years ago
parent
commit
3b150d4d86
1 changed files with 6 additions and 0 deletions
  1. 6 0
      lib/Predis.php

+ 6 - 0
lib/Predis.php

@@ -427,6 +427,12 @@ class ResponseReader {
 
     public function getOption($option) {
         switch ($option) {
+            case 'iterable_multibulk_replies':
+            case 'iterableMultiBulkReplies':
+                return $this->_prefixHandlers['*'] instanceof ResponseMultiBulkStreamHandler;
+            case 'errorThrowException':
+            case 'error_throw_exception':
+                return $this->_prefixHandlers['*'] instanceof ResponseErrorHandler;
             default:
                 throw new \InvalidArgumentException("Unknown option: $option");
         }