Completed
Pull Request — develop (#3255)
by Michael
83:40 queued 22:31
created

StringType::getDefaultLength()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 3
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 1
nc 1
nop 1
crap 1
1
<?php
2
3
namespace Doctrine\DBAL\Types;
4
5
use Doctrine\DBAL\Platforms\AbstractPlatform;
6
7
/**
8
 * Type that maps an SQL VARCHAR to a PHP string.
9
 *
10
 * @since 2.0
11
 */
12
class StringType extends Type
13
{
14
    /**
15
     * {@inheritdoc}
16
     */
17 3927
    public function getSQLDeclaration(array $fieldDeclaration, AbstractPlatform $platform)
18
    {
19 3927
        return $platform->getVarcharTypeDeclarationSQL($fieldDeclaration);
20
    }
21
22
    /**
23
     * {@inheritdoc}
24
     */
25 16
    public function getName()
26
    {
27 16
        return Type::STRING;
28
    }
29
}
30