PluginProbe
User Access Manager / trunk
User Access Manager vtrunk
2.3.20 2.3.19 2.3.18 2.3.17 2.3.16 2.3.15 2.3.14 2.3.13 trunk 0.6 0.6.1 0.6.2 0.7 0.7 Beta 0.7.0.1 0.8 0.8.0.1 0.8.0.2 0.9 0.9.1 0.9.1.1 0.9.1.2 0.9.1.3 0.9.1.4 1.0 All 136 releases
user-access-manager / src / Setup / Database / DatabaseObjectFactory.php

DatabaseObjectFactory.php in User Access Manager trunk, at src/Setup/Database/DatabaseObjectFactory.php

28 lines 645 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 declare(strict_types=1);
4
5 namespace UserAccessManager\Setup\Database;
6
7 class DatabaseObjectFactory
8 {
9 /**
10 * @throws MissingColumnsException
11 */
12 public function createTable(string $name, string $charsetCollate, array $columns): Table
13 {
14 return new Table($name, $charsetCollate, $columns);
15 }
16
17 public function createColumn(
18 string $name,
19 string $type,
20 bool $isNull = false,
21 mixed $default = null,
22 bool $isKey = false,
23 bool $isAutoIncrement = false
24 ): Column {
25 return new Column($name, $type, $isNull, $default, $isKey, $isAutoIncrement);
26 }
27 }
28