use of org.locationtech.geowave.core.store.adapter.MockComponents.MockAbstractDataAdapter in project geowave by locationtech.
the class DataStoreAddTest method addIndex_SameIndexVarArgs.
@Test
public void addIndex_SameIndexVarArgs() {
final NullIndex index1 = new NullIndex("index1");
final NullIndex index2 = new NullIndex("index2");
final MockAbstractDataAdapter adapter = new MockAbstractDataAdapter(MOCK_DATA_TYPE_1);
dataStore.addType(adapter, index1);
dataStore.addIndex(MOCK_DATA_TYPE_1, index2, index2, index2);
assertEquals(2, dataStore.getIndices(MOCK_DATA_TYPE_1).length);
}
use of org.locationtech.geowave.core.store.adapter.MockComponents.MockAbstractDataAdapter in project geowave by locationtech.
the class DataStoreAddTest method addIndex_IndexAlreadyAdded.
@Test
public void addIndex_IndexAlreadyAdded() {
final NullIndex index1 = new NullIndex("index1");
final MockAbstractDataAdapter adapter = new MockAbstractDataAdapter(MOCK_DATA_TYPE_1);
dataStore.addType(adapter, index1);
dataStore.addIndex(MOCK_DATA_TYPE_1, index1);
assertEquals(1, dataStore.getIndices(MOCK_DATA_TYPE_1).length);
}
use of org.locationtech.geowave.core.store.adapter.MockComponents.MockAbstractDataAdapter in project geowave by locationtech.
the class DataStoreAddTest method createWriter_SeenTypeWriteNoError.
@Test
public void createWriter_SeenTypeWriteNoError() {
final NullIndex index = new NullIndex("myIndex");
final MockAbstractDataAdapter adapter = new MockAbstractDataAdapter(MOCK_DATA_TYPE_1);
dataStore.addType(adapter, index);
final Writer<Integer> writer = dataStore.createWriter(MOCK_DATA_TYPE_1);
writer.write(15);
writer.write(0);
writer.close();
}
use of org.locationtech.geowave.core.store.adapter.MockComponents.MockAbstractDataAdapter in project geowave by locationtech.
the class DataStoreAddTest method createWriter_NonNullForSeenType.
@Test
public void createWriter_NonNullForSeenType() {
final NullIndex index = new NullIndex("myIndex");
final MockAbstractDataAdapter adapter = new MockAbstractDataAdapter(MOCK_DATA_TYPE_1);
dataStore.addType(adapter, index);
final Writer<Integer> writer = dataStore.createWriter(MOCK_DATA_TYPE_1);
assertNotNull(writer);
}
use of org.locationtech.geowave.core.store.adapter.MockComponents.MockAbstractDataAdapter in project geowave by locationtech.
the class DataStoreAddTest method addType_Basic.
@Test
public void addType_Basic() {
final NullIndex index = new NullIndex("myIndex");
final MockAbstractDataAdapter adapter = new MockAbstractDataAdapter(MOCK_DATA_TYPE_1);
dataStore.addType(adapter, index);
final DataTypeAdapter<?>[] registeredTypes = dataStore.getTypes();
assertEquals(1, registeredTypes.length);
assertTrue(registeredTypes[0] instanceof MockAbstractDataAdapter);
}
Aggregations