IsAExpectation::canonicalType PHP Méthode

canonicalType() protected méthode

Coerces type name into a is_*() match.
protected canonicalType ( string $type ) : string
$type string User type.
Résultat string Simpler type.
    protected function canonicalType($type)
    {
        $type = strtolower($type);
        $map = array('boolean' => 'bool');
        if (isset($map[$type])) {
            $type = $map[$type];
        }
        return $type;
    }