Search in sources :

Example 1 with AdvertisedDataSource

use of org.voltdb.export.AdvertisedDataSource in project voltdb by VoltDB.

the class ExportClientTestBase method constructTestSource.

static AdvertisedDataSource constructTestSource(boolean replicated, int partition, String tableName) {
    ArrayList<String> col_names = new ArrayList<String>();
    ArrayList<VoltType> col_types = new ArrayList<VoltType>();
    for (int i = 0; i < COLUMN_TYPES.length; i++) {
        col_names.add(COLUMN_NAMES[i]);
        col_types.add(COLUMN_TYPES[i]);
    }
    String partCol = replicated ? null : "smallint";
    //clear the table
    vtable.clearRowData();
    AdvertisedDataSource source = new AdvertisedDataSource(partition, "foo", tableName, partCol, 0, 32, col_names, col_types, Arrays.asList(COLUMN_LENGTHS), AdvertisedDataSource.ExportFormat.FOURDOTFOUR);
    return source;
}
Also used : AdvertisedDataSource(org.voltdb.export.AdvertisedDataSource) VoltType(org.voltdb.VoltType) ArrayList(java.util.ArrayList)

Aggregations

ArrayList (java.util.ArrayList)1 VoltType (org.voltdb.VoltType)1 AdvertisedDataSource (org.voltdb.export.AdvertisedDataSource)1