protected function _addQuery($type, $args)
{
if (!is_array($args) && !$args instanceof AbstractQuery) {
throw new InvalidException('Invalid parameter. Has to be array or instance of Elastica\\Query\\AbstractQuery');
}
return $this->addParam($type, $args);
}