original_string: public function shards($key = null)
      {
          $shards = $this->response['_shards'];
  
          if ($key and isset($shards[$key])) {
              return $shards[$key];
          }
  
          return $shards;
      }
code: public function shards($key = null)
      {
          $shards = $this->response['_shards'];
  
          if ($key and isset($shards[$key])) {
              return $shards[$key];
          }
  
          return $shards;
      }
code_tokens: public function shards ( $ key = null ) { $ shards = $ this -> response [ '_shards' ] ; if ( $ key and isset ( $ shards [ $ key ] ) ) { return $ shards [ $ key ] ; } return $ shards ; }
docstring: Shards information.
  
  @param null|string $key
  @return array|string
docstring_tokens: Shards information .