public function updateObjects($type, array $query, array $data)
    {
        $type = $this->getFullType($type);
        if (class_exists($type)) {
            $collection = $type::getCollection();
            $result = $this->mongodb->$collection->update($query, ['$set' => $data], ['multiple' => true]);
            return $result['ok'] ? $result['n'] : false;
        }
        return false;
    }