mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-20 06:32:08 +00:00
24 lines
593 B
C++
24 lines
593 B
C++
|
#include <DataTypes/DataTypeDate32.h>
|
||
|
#include <DataTypes/DataTypeFactory.h>
|
||
|
#include <DataTypes/Serializations/SerializationDate32.h>
|
||
|
|
||
|
namespace DB
|
||
|
{
|
||
|
bool DataTypeDate32::equals(const IDataType & rhs) const
|
||
|
{
|
||
|
return typeid(rhs) == typeid(*this);
|
||
|
}
|
||
|
|
||
|
SerializationPtr DataTypeDate32::doGetDefaultSerialization() const
|
||
|
{
|
||
|
return std::make_shared<SerializationDate32>();
|
||
|
}
|
||
|
|
||
|
void registerDataTypeDate32(DataTypeFactory & factory)
|
||
|
{
|
||
|
factory.registerSimpleDataType(
|
||
|
"Date32", [] { return DataTypePtr(std::make_shared<DataTypeDate32>()); }, DataTypeFactory::CaseInsensitive);
|
||
|
}
|
||
|
|
||
|
}
|