@@ -82,7 +82,7 @@ |
||
| 82 | 82 | } |
| 83 | 83 | |
| 84 | 84 | /** |
| 85 | - * @param array $stmts |
|
| 85 | + * @param Node[] $stmts |
|
| 86 | 86 | * @param string $classname |
| 87 | 87 | * @return Node|null |
| 88 | 88 | */ |
@@ -9,7 +9,6 @@ |
||
| 9 | 9 | use Symfony\Component\Finder\Finder; |
| 10 | 10 | use Taisiya\CoreBundle\Composer\ScriptHandler as CoreScriptHandler; |
| 11 | 11 | use Taisiya\PropelBundle\Database\Schema; |
| 12 | -use Taisiya\PropelBundle\Database\SchemaFactory; |
|
| 13 | 12 | |
| 14 | 13 | defined('TAISIYA_ROOT') || define('TAISIYA_ROOT', dirname(dirname(__DIR__))); |
| 15 | 14 | |
@@ -196,7 +196,7 @@ discard block |
||
| 196 | 196 | */ |
| 197 | 197 | final public function getForeignKey(string $name): ForeignKey |
| 198 | 198 | { |
| 199 | - if (! $this->hasForeignKey($name)) { |
|
| 199 | + if (!$this->hasForeignKey($name)) { |
|
| 200 | 200 | throw new InvalidArgumentException('Foreign key '.$name.' not added.'); |
| 201 | 201 | } |
| 202 | 202 | |
@@ -215,7 +215,7 @@ discard block |
||
| 215 | 215 | /** |
| 216 | 216 | * @return null|string |
| 217 | 217 | */ |
| 218 | - final public function getPhpName(): ?string |
|
| 218 | + final public function getPhpName(): ? string |
|
| 219 | 219 | { |
| 220 | 220 | return $this->phpName; |
| 221 | 221 | } |
@@ -233,7 +233,7 @@ discard block |
||
| 233 | 233 | /** |
| 234 | 234 | * @return null|string |
| 235 | 235 | */ |
| 236 | - final public function getTableMapName(): ?string |
|
| 236 | + final public function getTableMapName(): ? string |
|
| 237 | 237 | { |
| 238 | 238 | return $this->tableMapName; |
| 239 | 239 | } |
@@ -287,7 +287,7 @@ discard block |
||
| 287 | 287 | /** |
| 288 | 288 | * @return null|string |
| 289 | 289 | */ |
| 290 | - final public function getType(): ?string |
|
| 290 | + final public function getType(): ? string |
|
| 291 | 291 | { |
| 292 | 292 | return $this->type; |
| 293 | 293 | } |
@@ -346,7 +346,7 @@ discard block |
||
| 346 | 346 | /** |
| 347 | 347 | * @return null|string |
| 348 | 348 | */ |
| 349 | - final public function getPhpType(): ?string |
|
| 349 | + final public function getPhpType(): ? string |
|
| 350 | 350 | { |
| 351 | 351 | return $this->phpType; |
| 352 | 352 | } |
@@ -364,7 +364,7 @@ discard block |
||
| 364 | 364 | /** |
| 365 | 365 | * @return null|string |
| 366 | 366 | */ |
| 367 | - final public function getSqlType(): ?string |
|
| 367 | + final public function getSqlType(): ? string |
|
| 368 | 368 | { |
| 369 | 369 | return $this->sqlType; |
| 370 | 370 | } |
@@ -406,7 +406,7 @@ discard block |
||
| 406 | 406 | /** |
| 407 | 407 | * @return int|null |
| 408 | 408 | */ |
| 409 | - final public function getSize(): ?int |
|
| 409 | + final public function getSize(): ? int |
|
| 410 | 410 | { |
| 411 | 411 | return $this->size; |
| 412 | 412 | } |
@@ -424,7 +424,7 @@ discard block |
||
| 424 | 424 | /** |
| 425 | 425 | * @return int|null |
| 426 | 426 | */ |
| 427 | - final public function getScale(): ?int |
|
| 427 | + final public function getScale(): ? int |
|
| 428 | 428 | { |
| 429 | 429 | return $this->scale; |
| 430 | 430 | } |
@@ -442,7 +442,7 @@ discard block |
||
| 442 | 442 | /** |
| 443 | 443 | * @return null|string |
| 444 | 444 | */ |
| 445 | - final public function getDefaultvalue(): ?string |
|
| 445 | + final public function getDefaultvalue(): ? string |
|
| 446 | 446 | { |
| 447 | 447 | return $this->defaultvalue; |
| 448 | 448 | } |
@@ -460,7 +460,7 @@ discard block |
||
| 460 | 460 | /** |
| 461 | 461 | * @return null|string |
| 462 | 462 | */ |
| 463 | - final public function getDefaultExpr(): ?string |
|
| 463 | + final public function getDefaultExpr(): ? string |
|
| 464 | 464 | { |
| 465 | 465 | return $this->defaultExpr; |
| 466 | 466 | } |
@@ -478,7 +478,7 @@ discard block |
||
| 478 | 478 | /** |
| 479 | 479 | * @return null|string |
| 480 | 480 | */ |
| 481 | - final public function getValueSet(): ?string |
|
| 481 | + final public function getValueSet(): ? string |
|
| 482 | 482 | { |
| 483 | 483 | return $this->valueSet; |
| 484 | 484 | } |
@@ -532,7 +532,7 @@ discard block |
||
| 532 | 532 | /** |
| 533 | 533 | * @return null|string |
| 534 | 534 | */ |
| 535 | - final public function getDescription(): ?string |
|
| 535 | + final public function getDescription(): ? string |
|
| 536 | 536 | { |
| 537 | 537 | return $this->description; |
| 538 | 538 | } |
@@ -586,7 +586,7 @@ discard block |
||
| 586 | 586 | /** |
| 587 | 587 | * @return bool|string |
| 588 | 588 | */ |
| 589 | - final public function getInheritance(): ?string |
|
| 589 | + final public function getInheritance(): ? string |
|
| 590 | 590 | { |
| 591 | 591 | return $this->inheritance; |
| 592 | 592 | } |
@@ -36,7 +36,7 @@ |
||
| 36 | 36 | /** |
| 37 | 37 | * @return int|null |
| 38 | 38 | */ |
| 39 | - public function getSize(): ?int |
|
| 39 | + public function getSize(): ? int |
|
| 40 | 40 | { |
| 41 | 41 | return $this->size; |
| 42 | 42 | } |
@@ -99,7 +99,7 @@ |
||
| 99 | 99 | /** |
| 100 | 100 | * @return null|string |
| 101 | 101 | */ |
| 102 | - final public function getForeignSchema(): ?string |
|
| 102 | + final public function getForeignSchema(): ? string |
|
| 103 | 103 | { |
| 104 | 104 | return $this->foreignSchema; |
| 105 | 105 | } |
@@ -85,7 +85,7 @@ |
||
| 85 | 85 | |
| 86 | 86 | public function hasDatabaseByClassName(string $className): bool |
| 87 | 87 | { |
| 88 | - if (! class_exists($className)) { |
|
| 88 | + if (!class_exists($className)) { |
|
| 89 | 89 | throw new InvalidArgumentException('Class '.$className.' not exists.'); |
| 90 | 90 | } |
| 91 | 91 | $reflectionClass = new \ReflectionClass($className); |
@@ -28,7 +28,7 @@ discard block |
||
| 28 | 28 | } |
| 29 | 29 | |
| 30 | 30 | /** |
| 31 | - * @param Database $database |
|
| 31 | + * @param TestDatabase\TestDatabase $database |
|
| 32 | 32 | * @return Schema |
| 33 | 33 | */ |
| 34 | 34 | public function createDatabaseIfNotExists(Database $database): self |
@@ -41,7 +41,7 @@ discard block |
||
| 41 | 41 | } |
| 42 | 42 | |
| 43 | 43 | /** |
| 44 | - * @param Database $database |
|
| 44 | + * @param TestDatabase\TestDatabase $database |
|
| 45 | 45 | * @throws InvalidArgumentException |
| 46 | 46 | * @return Schema |
| 47 | 47 | */ |
@@ -180,7 +180,7 @@ discard block |
||
| 180 | 180 | /** |
| 181 | 181 | * @return null|string |
| 182 | 182 | */ |
| 183 | - final public function getPackage(): ?string |
|
| 183 | + final public function getPackage(): ? string |
|
| 184 | 184 | { |
| 185 | 185 | return $this->package; |
| 186 | 186 | } |
@@ -199,7 +199,7 @@ discard block |
||
| 199 | 199 | /** |
| 200 | 200 | * @return null|string |
| 201 | 201 | */ |
| 202 | - final public function getSchema(): ?string |
|
| 202 | + final public function getSchema(): ? string |
|
| 203 | 203 | { |
| 204 | 204 | return $this->schema; |
| 205 | 205 | } |
@@ -218,7 +218,7 @@ discard block |
||
| 218 | 218 | /** |
| 219 | 219 | * @return null|string |
| 220 | 220 | */ |
| 221 | - final public function getNamespace(): ?string |
|
| 221 | + final public function getNamespace(): ? string |
|
| 222 | 222 | { |
| 223 | 223 | return $this->namespace; |
| 224 | 224 | } |
@@ -237,7 +237,7 @@ discard block |
||
| 237 | 237 | /** |
| 238 | 238 | * @return null|string |
| 239 | 239 | */ |
| 240 | - final public function getBaseClass(): ?string |
|
| 240 | + final public function getBaseClass(): ? string |
|
| 241 | 241 | { |
| 242 | 242 | return $this->baseClass; |
| 243 | 243 | } |
@@ -325,7 +325,7 @@ discard block |
||
| 325 | 325 | /** |
| 326 | 326 | * @return null|string |
| 327 | 327 | */ |
| 328 | - final public function getTablePrefix(): ?string |
|
| 328 | + final public function getTablePrefix(): ? string |
|
| 329 | 329 | { |
| 330 | 330 | return $this->tablePrefix; |
| 331 | 331 | } |
@@ -75,7 +75,7 @@ discard block |
||
| 75 | 75 | |
| 76 | 76 | $this->columns = array_filter( |
| 77 | 77 | $this->columns, |
| 78 | - function (IndexColumn $indexColumn) use ($name) { |
|
| 78 | + function(IndexColumn $indexColumn) use ($name) { |
|
| 79 | 79 | $column = $indexColumn->getColumn(); |
| 80 | 80 | return (bool) ($column::getName() !== $name); |
| 81 | 81 | } |
@@ -88,7 +88,7 @@ discard block |
||
| 88 | 88 | * @param string $name |
| 89 | 89 | * @return null|IndexColumn |
| 90 | 90 | */ |
| 91 | - final public function findIndexColumnByName(string $name): ?IndexColumn |
|
| 91 | + final public function findIndexColumnByName(string $name): ? IndexColumn |
|
| 92 | 92 | { |
| 93 | 93 | /** @var IndexColumn $indexColumn */ |
| 94 | 94 | foreach ($this->columns as $indexColumn) { |
@@ -184,7 +184,7 @@ discard block |
||
| 184 | 184 | /** |
| 185 | 185 | * @return string|null |
| 186 | 186 | */ |
| 187 | - final public function getPhpName(): ?string |
|
| 187 | + final public function getPhpName(): ? string |
|
| 188 | 188 | { |
| 189 | 189 | return $this->phpName; |
| 190 | 190 | } |
@@ -279,7 +279,7 @@ discard block |
||
| 279 | 279 | /** |
| 280 | 280 | * @return null|string |
| 281 | 281 | */ |
| 282 | - final public function getPackage(): ?string |
|
| 282 | + final public function getPackage(): ? string |
|
| 283 | 283 | { |
| 284 | 284 | return $this->package; |
| 285 | 285 | } |
@@ -298,7 +298,7 @@ discard block |
||
| 298 | 298 | /** |
| 299 | 299 | * @return null|string |
| 300 | 300 | */ |
| 301 | - final public function getSchema(): ?string |
|
| 301 | + final public function getSchema(): ? string |
|
| 302 | 302 | { |
| 303 | 303 | return $this->schema; |
| 304 | 304 | } |
@@ -317,7 +317,7 @@ discard block |
||
| 317 | 317 | /** |
| 318 | 318 | * @return null|string |
| 319 | 319 | */ |
| 320 | - final public function getNamespace(): ?string |
|
| 320 | + final public function getNamespace(): ? string |
|
| 321 | 321 | { |
| 322 | 322 | return $this->namespace; |
| 323 | 323 | } |
@@ -404,7 +404,7 @@ discard block |
||
| 404 | 404 | /** |
| 405 | 405 | * @return null|string |
| 406 | 406 | */ |
| 407 | - final public function getBaseClass(): ?string |
|
| 407 | + final public function getBaseClass(): ? string |
|
| 408 | 408 | { |
| 409 | 409 | return $this->baseClass; |
| 410 | 410 | } |
@@ -423,7 +423,7 @@ discard block |
||
| 423 | 423 | /** |
| 424 | 424 | * @return null|string |
| 425 | 425 | */ |
| 426 | - final public function getDescription(): ?string |
|
| 426 | + final public function getDescription(): ? string |
|
| 427 | 427 | { |
| 428 | 428 | return $this->description; |
| 429 | 429 | } |
@@ -499,7 +499,7 @@ discard block |
||
| 499 | 499 | /** |
| 500 | 500 | * @return null|string |
| 501 | 501 | */ |
| 502 | - final public function getTreeMode(): ?string |
|
| 502 | + final public function getTreeMode(): ? string |
|
| 503 | 503 | { |
| 504 | 504 | return $this->treeMode; |
| 505 | 505 | } |
@@ -8,7 +8,7 @@ discard block |
||
| 8 | 8 | trait XMLAssertsTrait |
| 9 | 9 | { |
| 10 | 10 | /** |
| 11 | - * @param string|\DOMDocument $xml |
|
| 11 | + * @param string $xml |
|
| 12 | 12 | * @param string $version |
| 13 | 13 | * @param string $encoding |
| 14 | 14 | * @param string $message |
@@ -19,7 +19,7 @@ discard block |
||
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | /** |
| 22 | - * @param string|\DOMDocument $xml |
|
| 22 | + * @param string $xml |
|
| 23 | 23 | * @param string $query |
| 24 | 24 | * @param int|null $count |
| 25 | 25 | * @param string $message |