Search in sources :

Example 1 with P4HyperLogLogType

use of io.prestosql.spi.type.P4HyperLogLogType in project hetu-core by openlookeng.

the class TestTypeUtil method testParseType.

@Test
public void testParseType() {
    Type type = parseType(typeManager, "bigint");
    assertTrue(type instanceof BigintType);
    type = parseType(typeManager, "integer");
    assertTrue(type instanceof IntegerType);
    type = parseType(typeManager, "smallint");
    assertTrue(type instanceof SmallintType);
    type = parseType(typeManager, "boolean");
    assertTrue(type instanceof BooleanType);
    type = parseType(typeManager, "date");
    assertTrue(type instanceof DateType);
    type = parseType(typeManager, "real");
    assertTrue(type instanceof RealType);
    type = parseType(typeManager, "double");
    assertTrue(type instanceof DoubleType);
    type = parseType(typeManager, "HyperLogLog");
    assertTrue(type instanceof HyperLogLogType);
    type = parseType(typeManager, "P4HyperLogLog");
    assertTrue(type instanceof P4HyperLogLogType);
    type = parseType(typeManager, "timestamp");
    assertTrue(type instanceof TimestampType);
    type = parseType(typeManager, "timestamp with time zone");
    assertTrue(type instanceof TimestampWithTimeZoneType);
    type = parseType(typeManager, "time");
    assertTrue(type instanceof TimeType);
    type = parseType(typeManager, "time with time zone");
    assertTrue(type instanceof TimeWithTimeZoneType);
    type = parseType(typeManager, "varbinary");
    assertTrue(type instanceof VarbinaryType);
    type = parseType(typeManager, "unknown");
    assertTrue(type instanceof UnknownType);
}
Also used : BooleanType(io.prestosql.spi.type.BooleanType) P4HyperLogLogType(io.prestosql.spi.type.P4HyperLogLogType) TimeWithTimeZoneType(io.prestosql.spi.type.TimeWithTimeZoneType) RealType(io.prestosql.spi.type.RealType) BigintType(io.prestosql.spi.type.BigintType) TimeType(io.prestosql.spi.type.TimeType) IntegerType(io.prestosql.spi.type.IntegerType) UnknownType(io.prestosql.spi.type.UnknownType) BigintType(io.prestosql.spi.type.BigintType) UnknownType(io.prestosql.spi.type.UnknownType) CharType(io.prestosql.spi.type.CharType) DecimalType(io.prestosql.spi.type.DecimalType) HyperLogLogType(io.prestosql.spi.type.HyperLogLogType) DoubleType(io.prestosql.spi.type.DoubleType) P4HyperLogLogType(io.prestosql.spi.type.P4HyperLogLogType) RowType(io.prestosql.spi.type.RowType) TimestampWithTimeZoneType(io.prestosql.spi.type.TimestampWithTimeZoneType) Type(io.prestosql.spi.type.Type) SmallintType(io.prestosql.spi.type.SmallintType) TimeWithTimeZoneType(io.prestosql.spi.type.TimeWithTimeZoneType) IntegerType(io.prestosql.spi.type.IntegerType) TimeType(io.prestosql.spi.type.TimeType) RealType(io.prestosql.spi.type.RealType) ArrayType(io.prestosql.spi.type.ArrayType) VarbinaryType(io.prestosql.spi.type.VarbinaryType) TimestampType(io.prestosql.spi.type.TimestampType) DateType(io.prestosql.spi.type.DateType) BooleanType(io.prestosql.spi.type.BooleanType) TypeUtil.parseType(io.prestosql.client.util.TypeUtil.parseType) VarcharType(io.prestosql.spi.type.VarcharType) HyperLogLogType(io.prestosql.spi.type.HyperLogLogType) P4HyperLogLogType(io.prestosql.spi.type.P4HyperLogLogType) VarbinaryType(io.prestosql.spi.type.VarbinaryType) DoubleType(io.prestosql.spi.type.DoubleType) TimestampWithTimeZoneType(io.prestosql.spi.type.TimestampWithTimeZoneType) TimestampType(io.prestosql.spi.type.TimestampType) SmallintType(io.prestosql.spi.type.SmallintType) DateType(io.prestosql.spi.type.DateType) Test(org.testng.annotations.Test)

Aggregations

TypeUtil.parseType (io.prestosql.client.util.TypeUtil.parseType)1 ArrayType (io.prestosql.spi.type.ArrayType)1 BigintType (io.prestosql.spi.type.BigintType)1 BooleanType (io.prestosql.spi.type.BooleanType)1 CharType (io.prestosql.spi.type.CharType)1 DateType (io.prestosql.spi.type.DateType)1 DecimalType (io.prestosql.spi.type.DecimalType)1 DoubleType (io.prestosql.spi.type.DoubleType)1 HyperLogLogType (io.prestosql.spi.type.HyperLogLogType)1 IntegerType (io.prestosql.spi.type.IntegerType)1 P4HyperLogLogType (io.prestosql.spi.type.P4HyperLogLogType)1 RealType (io.prestosql.spi.type.RealType)1 RowType (io.prestosql.spi.type.RowType)1 SmallintType (io.prestosql.spi.type.SmallintType)1 TimeType (io.prestosql.spi.type.TimeType)1 TimeWithTimeZoneType (io.prestosql.spi.type.TimeWithTimeZoneType)1 TimestampType (io.prestosql.spi.type.TimestampType)1 TimestampWithTimeZoneType (io.prestosql.spi.type.TimestampWithTimeZoneType)1 Type (io.prestosql.spi.type.Type)1 UnknownType (io.prestosql.spi.type.UnknownType)1