Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | |
0.00% |
0 / 4 |
|
0.00% |
0 / 1 |
CRAP | |
0.00% |
0 / 1 |
MWMySQLPlatform | |
0.00% |
0 / 4 |
|
0.00% |
0 / 1 |
12 | |
0.00% |
0 / 1 |
getFloatDeclarationSQL | |
0.00% |
0 / 4 |
|
0.00% |
0 / 1 |
12 |
1 | <?php |
2 | |
3 | namespace Wikimedia\Rdbms; |
4 | |
5 | use Doctrine\DBAL\Platforms\MySQLPlatform; |
6 | |
7 | class MWMySQLPlatform extends MySQLPlatform { |
8 | |
9 | /** |
10 | * @inheritDoc |
11 | */ |
12 | public function getFloatDeclarationSQL( array $column ) { |
13 | $double = $column['doublePrecision'] ?? false; |
14 | $unsigned = $column['unsigned'] ?? false; |
15 | |
16 | $sql = $double ? 'DOUBLE PRECISION' : 'FLOAT'; |
17 | |
18 | return $sql . ( $unsigned ? ' UNSIGNED' : '' ); |
19 | } |
20 | } |