Search in sources :

Example 1 with PersonNameFieldValueGenerator

use of org.apache.hyracks.storage.am.common.datagen.PersonNameFieldValueGenerator in project asterixdb by apache.

the class LSMInvertedIndexTestUtils method createPersonNamesTupleGen.

public static TupleGenerator createPersonNamesTupleGen(Random rnd) throws IOException {
    IFieldValueGenerator[] fieldGens = new IFieldValueGenerator[2];
    fieldGens[0] = new PersonNameFieldValueGenerator(rnd, 0.5f);
    fieldGens[1] = new SortedIntegerFieldValueGenerator(0);
    ISerializerDeserializer[] fieldSerdes = new ISerializerDeserializer[] { new UTF8StringSerializerDeserializer(), IntegerSerializerDeserializer.INSTANCE };
    TupleGenerator tupleGen = new TupleGenerator(fieldGens, fieldSerdes, 0);
    return tupleGen;
}
Also used : SortedIntegerFieldValueGenerator(org.apache.hyracks.storage.am.common.datagen.SortedIntegerFieldValueGenerator) PersonNameFieldValueGenerator(org.apache.hyracks.storage.am.common.datagen.PersonNameFieldValueGenerator) IFieldValueGenerator(org.apache.hyracks.storage.am.common.datagen.IFieldValueGenerator) TupleGenerator(org.apache.hyracks.storage.am.common.datagen.TupleGenerator) UTF8StringSerializerDeserializer(org.apache.hyracks.dataflow.common.data.marshalling.UTF8StringSerializerDeserializer) ISerializerDeserializer(org.apache.hyracks.api.dataflow.value.ISerializerDeserializer)

Aggregations

ISerializerDeserializer (org.apache.hyracks.api.dataflow.value.ISerializerDeserializer)1 UTF8StringSerializerDeserializer (org.apache.hyracks.dataflow.common.data.marshalling.UTF8StringSerializerDeserializer)1 IFieldValueGenerator (org.apache.hyracks.storage.am.common.datagen.IFieldValueGenerator)1 PersonNameFieldValueGenerator (org.apache.hyracks.storage.am.common.datagen.PersonNameFieldValueGenerator)1 SortedIntegerFieldValueGenerator (org.apache.hyracks.storage.am.common.datagen.SortedIntegerFieldValueGenerator)1 TupleGenerator (org.apache.hyracks.storage.am.common.datagen.TupleGenerator)1