/** * @param array $params Parameters: * - collection: (string) The name of the storage collection. * - mongo_db: (Horde_Mongo_Client) [REQUIRED] The DB instance. */ public function __construct(array $params = array()) { if (!isset($params['mongo_db'])) { throw new InvalidArgumentException('Missing mongo_db parameter.'); } parent::__construct(array_merge(array('collection' => 'ingo_storage'), $params)); $this->_params['db'] = $this->_params['mongo_db']->selectCollection(null, $this->_params['collection']); }