|
20 | 20 | namespace Doctrine\ODM\MongoDB\Types;
|
21 | 21 |
|
22 | 22 | use Doctrine\ODM\MongoDB\Mapping\MappingException;
|
| 23 | +use Doctrine\ODM\MongoDB\Types; |
23 | 24 |
|
24 | 25 | /**
|
25 | 26 | * The Type interface.
|
26 | 27 | *
|
27 | 28 | * @since 1.0
|
28 | 29 | * @author Jonathan H. Wage <jonwage@gmail.com>
|
29 | 30 | * @author Roman Borschel <roman@code-factory.org>
|
| 31 | + * @author Jefersson Nathan <malukenho@phpse.net> |
30 | 32 | */
|
31 | 33 | abstract class Type
|
32 | 34 | {
|
@@ -61,31 +63,31 @@ abstract class Type
|
61 | 63 |
|
62 | 64 | /** The map of supported doctrine mapping types. */
|
63 | 65 | private static $typesMap = array(
|
64 |
| - self::ID => 'Doctrine\ODM\MongoDB\Types\IdType', |
65 |
| - self::INTID => 'Doctrine\ODM\MongoDB\Types\IntIdType', |
66 |
| - self::CUSTOMID => 'Doctrine\ODM\MongoDB\Types\CustomIdType', |
67 |
| - self::BOOL => 'Doctrine\ODM\MongoDB\Types\BooleanType', |
68 |
| - self::BOOLEAN => 'Doctrine\ODM\MongoDB\Types\BooleanType', |
69 |
| - self::INT => 'Doctrine\ODM\MongoDB\Types\IntType', |
70 |
| - self::INTEGER => 'Doctrine\ODM\MongoDB\Types\IntType', |
71 |
| - self::FLOAT => 'Doctrine\ODM\MongoDB\Types\FloatType', |
72 |
| - self::STRING => 'Doctrine\ODM\MongoDB\Types\StringType', |
73 |
| - self::DATE => 'Doctrine\ODM\MongoDB\Types\DateType', |
74 |
| - self::KEY => 'Doctrine\ODM\MongoDB\Types\KeyType', |
75 |
| - self::TIMESTAMP => 'Doctrine\ODM\MongoDB\Types\TimestampType', |
76 |
| - self::BINDATA => 'Doctrine\ODM\MongoDB\Types\BinDataType', |
77 |
| - self::BINDATAFUNC => 'Doctrine\ODM\MongoDB\Types\BinDataFuncType', |
78 |
| - self::BINDATABYTEARRAY => 'Doctrine\ODM\MongoDB\Types\BinDataByteArrayType', |
79 |
| - self::BINDATAUUID => 'Doctrine\ODM\MongoDB\Types\BinDataUUIDType', |
80 |
| - self::BINDATAUUIDRFC4122 => 'Doctrine\ODM\MongoDB\Types\BinDataUUIDRFC4122Type', |
81 |
| - self::BINDATAMD5 => 'Doctrine\ODM\MongoDB\Types\BinDataMD5Type', |
82 |
| - self::BINDATACUSTOM => 'Doctrine\ODM\MongoDB\Types\BinDataCustomType', |
83 |
| - self::FILE => 'Doctrine\ODM\MongoDB\Types\FileType', |
84 |
| - self::HASH => 'Doctrine\ODM\MongoDB\Types\HashType', |
85 |
| - self::COLLECTION => 'Doctrine\ODM\MongoDB\Types\CollectionType', |
86 |
| - self::INCREMENT => 'Doctrine\ODM\MongoDB\Types\IncrementType', |
87 |
| - self::OBJECTID => 'Doctrine\ODM\MongoDB\Types\ObjectIdType', |
88 |
| - self::RAW => 'Doctrine\ODM\MongoDB\Types\RawType', |
| 66 | + self::ID => Types\IdType::class, |
| 67 | + self::INTID => Types\IntIdType::class, |
| 68 | + self::CUSTOMID => Types\CustomIdType::class, |
| 69 | + self::BOOL => Types\BooleanType::class, |
| 70 | + self::BOOLEAN => Types\BooleanType::class, |
| 71 | + self::INT => Types\IntType::class, |
| 72 | + self::INTEGER => Types\IntType::class, |
| 73 | + self::FLOAT => Types\FloatType::class, |
| 74 | + self::STRING => Types\StringType::class, |
| 75 | + self::DATE => Types\DateType::class, |
| 76 | + self::KEY => Types\KeyType::class, |
| 77 | + self::TIMESTAMP => Types\TimestampType::class, |
| 78 | + self::BINDATA => Types\BinDataType::class, |
| 79 | + self::BINDATAFUNC => Types\BinDataFuncType::class, |
| 80 | + self::BINDATABYTEARRAY => Types\BinDataByteArrayType::class, |
| 81 | + self::BINDATAUUID => Types\BinDataUUIDType::class, |
| 82 | + self::BINDATAUUIDRFC4122 => Types\BinDataUUIDRFC4122Type::class, |
| 83 | + self::BINDATAMD5 => Types\BinDataMD5Type::class, |
| 84 | + self::BINDATACUSTOM => Types\BinDataCustomType::class, |
| 85 | + self::FILE => Types\FileType::class, |
| 86 | + self::HASH => Types\HashType::class, |
| 87 | + self::COLLECTION => Types\CollectionType::class, |
| 88 | + self::INCREMENT => Types\IncrementType::class, |
| 89 | + self::OBJECTID => Types\ObjectIdType::class, |
| 90 | + self::RAW => Types\RawType::class, |
89 | 91 | );
|
90 | 92 |
|
91 | 93 | /* Prevent instantiation and force use of the factory method. */
|
|
0 commit comments