Search in sources :

Example 6 with ValueCompressionHolder

use of org.apache.carbondata.core.datastore.compression.ValueCompressionHolder in project carbondata by apache.

the class ValueCompressionUtilTest method testToUnCompressNonDecimalForInt.

@Test
public void testToUnCompressNonDecimalForInt() {
    ValueCompressionHolder result = ValueCompressionUtil.getCompressionNonDecimal(DataType.INT);
    assertEquals(result.getClass(), CompressionNonDecimalInt.class);
}
Also used : ValueCompressionHolder(org.apache.carbondata.core.datastore.compression.ValueCompressionHolder) Test(org.junit.Test)

Example 7 with ValueCompressionHolder

use of org.apache.carbondata.core.datastore.compression.ValueCompressionHolder in project carbondata by apache.

the class ValueCompressionUtilTest method testToUnCompressNoneForShort.

@Test
public void testToUnCompressNoneForShort() {
    ValueCompressionHolder result = ValueCompressionUtil.getCompressionNone(DataType.SHORT, DataType.FLOAT);
    assertEquals(result.getClass(), CompressionNoneShort.class);
}
Also used : ValueCompressionHolder(org.apache.carbondata.core.datastore.compression.ValueCompressionHolder) Test(org.junit.Test)

Example 8 with ValueCompressionHolder

use of org.apache.carbondata.core.datastore.compression.ValueCompressionHolder in project carbondata by apache.

the class ValueCompressionUtilTest method testToUnCompressMaxMinForLong.

@Test
public void testToUnCompressMaxMinForLong() {
    ValueCompressionHolder result = ValueCompressionUtil.getCompressionDecimalMaxMin(DataType.LONG, null);
    assertEquals(result.getClass(), CompressionMaxMinLong.class);
}
Also used : ValueCompressionHolder(org.apache.carbondata.core.datastore.compression.ValueCompressionHolder) Test(org.junit.Test)

Example 9 with ValueCompressionHolder

use of org.apache.carbondata.core.datastore.compression.ValueCompressionHolder in project carbondata by apache.

the class ValueCompressionUtilTest method testToUnCompressNonDecimalMaxMinForLong.

@Test
public void testToUnCompressNonDecimalMaxMinForLong() {
    ValueCompressionHolder result = ValueCompressionUtil.getCompressionNonDecimalMaxMin(DataType.LONG);
    assertEquals(result.getClass(), CompressionNonDecimalMaxMinLong.class);
}
Also used : ValueCompressionHolder(org.apache.carbondata.core.datastore.compression.ValueCompressionHolder) Test(org.junit.Test)

Example 10 with ValueCompressionHolder

use of org.apache.carbondata.core.datastore.compression.ValueCompressionHolder in project carbondata by apache.

the class ValueCompressionUtilTest method testToUnCompressMaxMinForDouble.

@Test
public void testToUnCompressMaxMinForDouble() {
    ValueCompressionHolder result = ValueCompressionUtil.getCompressionDecimalMaxMin(DataType.DOUBLE, null);
    assertEquals(result.getClass(), CompressionMaxMinDefault.class);
}
Also used : ValueCompressionHolder(org.apache.carbondata.core.datastore.compression.ValueCompressionHolder) Test(org.junit.Test)

Aggregations

ValueCompressionHolder (org.apache.carbondata.core.datastore.compression.ValueCompressionHolder)25 Test (org.junit.Test)21 ByteBuffer (java.nio.ByteBuffer)3 MeasureColumnDataChunk (org.apache.carbondata.core.datastore.chunk.MeasureColumnDataChunk)3 WriterCompressModel (org.apache.carbondata.core.datastore.compression.WriterCompressModel)3 CarbonReadDataHolder (org.apache.carbondata.core.datastore.dataholder.CarbonReadDataHolder)3 ValueEncoderMeta (org.apache.carbondata.core.metadata.ValueEncoderMeta)3 ArrayList (java.util.ArrayList)2 DataChunk2 (org.apache.carbondata.format.DataChunk2)2 ReaderCompressModel (org.apache.carbondata.core.datastore.compression.ReaderCompressModel)1 DataChunk (org.apache.carbondata.core.metadata.blocklet.datachunk.DataChunk)1 DataType (org.apache.carbondata.core.metadata.datatype.DataType)1 DataChunk3 (org.apache.carbondata.format.DataChunk3)1