code: function size($queue = null)
      {
          if ($queue === null) {
  
              $count = 0;
  
              /** @var iQueueDriver $queue */
              foreach ($this->channels_queue as $channel => $queue )
                  $count += $queue->size($channel);
  
          } else {
              if (false === $qd = $this->_getQueueOfChannel($queue) )
                  throw new \RuntimeException(sprintf(
                      'Channel (%s) is not present when trying to get size.'
                      , $queue
                  ));
  
              $count = $qd->size($queue);
          }
  
          return $count;
      }
docs: Get Queue Size
  
  @param string $queue
  
  @return int
  @throws exIOError