Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Schwan <carl@carlschwan.eu>2022-03-04 14:31:14 +0300
committerCarl Schwan <carl@carlschwan.eu>2022-03-05 16:35:34 +0300
commit5a17415dd8b68ec8eefbd38b599169aa0b818018 (patch)
treea4864ed6ba00ee5a14659cf943dfde1b67f56a1d
parent831aebf4f63835d0638d6cac656cd4bdcc863f31 (diff)
Add a few more non-extendable interfacedoc/manager-interface
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
-rw-r--r--lib/public/DB/IPreparedStatement.php9
-rw-r--r--lib/public/DB/IResult.php12
-rw-r--r--lib/public/DB/ISchemaWrapper.php7
3 files changed, 27 insertions, 1 deletions
diff --git a/lib/public/DB/IPreparedStatement.php b/lib/public/DB/IPreparedStatement.php
index 2fadff5da3f..391f987d20a 100644
--- a/lib/public/DB/IPreparedStatement.php
+++ b/lib/public/DB/IPreparedStatement.php
@@ -30,6 +30,15 @@ use Doctrine\DBAL\ParameterType;
use PDO;
/**
+ * This interface allows you to prepare a database query.
+ *
+ * This interface must not be implemented in your application but
+ * instead obtained from IDBConnection::prepare.
+ *
+ * ```php
+ * $prepare = $this->db->prepare($query->getSql());
+ * ```
+ *
* @since 21.0.0
*/
interface IPreparedStatement {
diff --git a/lib/public/DB/IResult.php b/lib/public/DB/IResult.php
index 76f8cf26601..cbed1e51dac 100644
--- a/lib/public/DB/IResult.php
+++ b/lib/public/DB/IResult.php
@@ -29,6 +29,18 @@ namespace OCP\DB;
use PDO;
/**
+ * This interface represents the result of a database query.
+ *
+ * Usage:
+ *
+ * ```php
+ * $qb = $this->db->getQueryBuilder();
+ * $qb->select(...);
+ * $result = $query->executeQuery();
+ * ```
+ *
+ * This interface must not be implemented in your application.
+ *
* @since 21.0.0
*/
interface IResult {
diff --git a/lib/public/DB/ISchemaWrapper.php b/lib/public/DB/ISchemaWrapper.php
index 82e4205f1b3..5c7ebaa7c30 100644
--- a/lib/public/DB/ISchemaWrapper.php
+++ b/lib/public/DB/ISchemaWrapper.php
@@ -26,7 +26,12 @@ use Doctrine\DBAL\Exception;
use Doctrine\DBAL\Platforms\AbstractPlatform;
/**
- * Interface ISchemaWrapper
+ * This interface allows to get information about the database schema.
+ * This is particularly helpful for database migration scripts.
+ *
+ * This interface must not be implemented in your application but
+ * instead can be obtained in your migration scripts with the
+ * `$schemaClosure` Closure.
*
* @since 13.0.0
*/