|
|
@@ -90,7 +90,14 @@ public:
|
|
|
Poco::SharedPtr<Poco::MongoDB::UpdateRequest> createUpdateRequest(const std::string& collectionName) const;
|
|
|
/// Creates an UpdateRequest. The collectionname must not contain the database name!
|
|
|
|
|
|
- Poco::MongoDB::Document::Ptr ensureIndex(Connection& connection, const std::string& collection, const std::string& indexName, Poco::MongoDB::Document::Ptr keys, bool unique = false, bool background = false, int version = 0, int ttl = 0);
|
|
|
+ Poco::MongoDB::Document::Ptr ensureIndex(Connection& connection,
|
|
|
+ const std::string& collection,
|
|
|
+ const std::string& indexName,
|
|
|
+ Poco::MongoDB::Document::Ptr keys,
|
|
|
+ bool unique = false,
|
|
|
+ bool background = false,
|
|
|
+ int version = 0,
|
|
|
+ int ttl = 0);
|
|
|
/// Creates an index. The document returned is the result of a getLastError call.
|
|
|
/// For more info look at the ensureIndex information on the MongoDB website.
|
|
|
|
|
|
@@ -114,25 +121,29 @@ inline Poco::SharedPtr<Poco::MongoDB::QueryRequest> Database::createCommand() co
|
|
|
}
|
|
|
|
|
|
|
|
|
-inline Poco::SharedPtr<Poco::MongoDB::DeleteRequest> Database::createDeleteRequest(const std::string& collectionName) const
|
|
|
+inline Poco::SharedPtr<Poco::MongoDB::DeleteRequest>
|
|
|
+Database::createDeleteRequest(const std::string& collectionName) const
|
|
|
{
|
|
|
return new Poco::MongoDB::DeleteRequest(_dbname + '.' + collectionName);
|
|
|
}
|
|
|
|
|
|
|
|
|
-inline Poco::SharedPtr<Poco::MongoDB::InsertRequest> Database::createInsertRequest(const std::string& collectionName) const
|
|
|
+inline Poco::SharedPtr<Poco::MongoDB::InsertRequest>
|
|
|
+Database::createInsertRequest(const std::string& collectionName) const
|
|
|
{
|
|
|
return new Poco::MongoDB::InsertRequest(_dbname + '.' + collectionName);
|
|
|
}
|
|
|
|
|
|
|
|
|
-inline Poco::SharedPtr<Poco::MongoDB::QueryRequest> Database::createQueryRequest(const std::string& collectionName) const
|
|
|
+inline Poco::SharedPtr<Poco::MongoDB::QueryRequest>
|
|
|
+Database::createQueryRequest(const std::string& collectionName) const
|
|
|
{
|
|
|
return new Poco::MongoDB::QueryRequest(_dbname + '.' + collectionName);
|
|
|
}
|
|
|
|
|
|
|
|
|
-inline Poco::SharedPtr<Poco::MongoDB::UpdateRequest> Database::createUpdateRequest(const std::string& collectionName) const
|
|
|
+inline Poco::SharedPtr<Poco::MongoDB::UpdateRequest>
|
|
|
+Database::createUpdateRequest(const std::string& collectionName) const
|
|
|
{
|
|
|
return new Poco::MongoDB::UpdateRequest(_dbname + '.' + collectionName);
|
|
|
}
|