1
0
Fork 0
mirror of synced 2024-06-27 10:41:00 +12:00

chore(migration): fixes phpdocs

This commit is contained in:
Torsten Dittmann 2021-01-18 15:43:55 +01:00
parent 64cae392d1
commit d4bf4027c1

View file

@ -6,26 +6,45 @@ use Appwrite\Database\Document;
use Appwrite\Database\Database; use Appwrite\Database\Database;
use Utopia\CLI\Console; use Utopia\CLI\Console;
use Utopia\Exception; use Utopia\Exception;
use PDO;
abstract class Migration abstract class Migration
{ {
protected \PDO $db; /**
* @var PDO
*/
protected PDO $db;
/**
* @var int
*/
protected int $limit = 30; protected int $limit = 30;
/**
* @var Document
*/
protected Document $project; protected Document $project;
/**
* @var Database
*/
protected Database $projectDB; protected Database $projectDB;
/** /**
* Migration constructor. * Migration constructor.
*
* @param PDO $pdo
*/ */
public function __construct(\PDO $db) public function __construct(PDO $db)
{ {
$this->db = $db; $this->db = $db;
} }
/** /**
* Set project for migration. * Set project for migration.
*
* @param Document $project
* @param Database $projectDB
*/ */
public function setProject(Document $project, Database $projectDB): Migration public function setProject(Document $project, Database $projectDB): Migration
{ {
@ -38,7 +57,7 @@ abstract class Migration
/** /**
* Iterates through every document. * Iterates through every document.
* *
* @param callable(Document):Document $callback * @param callable $callback
*/ */
public function forEachDocument(callable $callback) public function forEachDocument(callable $callback)
{ {