use of org.locationtech.geowave.service.grpc.protobuf.CQLQueryParametersProtos in project geowave by locationtech.
the class GeoWaveGrpcTestClient method cqlQuery.
public ArrayList<FeatureProtos> cqlQuery() throws UnsupportedEncodingException {
LOGGER.info("Performing CQL Query...");
final VectorStoreParametersProtos baseParams = VectorStoreParametersProtos.newBuilder().setStoreName(GeoWaveGrpcTestUtils.storeName).setTypeName(GeoWaveGrpcTestUtils.typeName).setIndexName(GeoWaveGrpcTestUtils.indexName).build();
final CQLQueryParametersProtos request = CQLQueryParametersProtos.newBuilder().setBaseParams(baseParams).setCql(GeoWaveGrpcTestUtils.cqlSpatialQuery).build();
Iterator<FeatureProtos> features;
final ArrayList<FeatureProtos> feature_list = new ArrayList<>();
features = vectorBlockingStub.cqlQuery(request);
// iterate over features
for (int i = 1; features.hasNext(); i++) {
final FeatureProtos feature = features.next();
feature_list.add(feature);
}
return feature_list;
}
Aggregations