test_class.declarator: DOUBLE_TOLERANCE = .00000001
test_class.modifier: private static final
test_class.original_string: private static final double DOUBLE_TOLERANCE = .00000001;
test_class.type: double
test_class.var_name: DOUBLE_TOLERANCE
test_class.declarator: LAYER_ID = "countries"
test_class.modifier: private static final
test_class.original_string: private static final String LAYER_ID = "countries";
test_class.type: String
test_class.var_name: LAYER_ID
test_class.declarator: REGION_ATTRIBUTE = "region"
test_class.modifier: private static final
test_class.original_string: private static final String REGION_ATTRIBUTE = "region";
test_class.type: String
test_class.var_name: REGION_ATTRIBUTE
test_class.declarator: NAME_ATTRIBUTE = "name"
test_class.modifier: private static final
test_class.original_string: private static final String NAME_ATTRIBUTE = "name";
test_class.type: String
test_class.var_name: NAME_ATTRIBUTE
test_class.declarator: ID_ATTRIBUTE = "id"
test_class.modifier: private static final
test_class.original_string: private static final String ID_ATTRIBUTE = "id";
test_class.type: String
test_class.var_name: ID_ATTRIBUTE
test_class.declarator: dispatcher
test_class.modifier: @Autowired
  	private
test_class.original_string: @Autowired
  	private CommandDispatcher dispatcher;
test_class.type: CommandDispatcher
test_class.var_name: dispatcher
test_class.declarator: searchFeatureCommand
test_class.modifier: @Autowired
  	private
test_class.original_string: @Autowired
  	private SearchFeatureCommand searchFeatureCommand;
test_class.type: SearchFeatureCommand
test_class.var_name: searchFeatureCommand
test_class.file: command/src/test/java/org/geomajas/command/feature/SearchFeatureCommandTest.java
test_class.identifier: SearchFeatureCommandTest
test_case.body: @Test
  	public void testSearchMultipleCriteria() throws Exception {
  		// prepare command
  		SearchFeatureRequest request = new SearchFeatureRequest();
  		request.setLayerId(LAYER_ID);
  		request.setCrs("EPSG:4326");
  		SearchCriterion searchCriterion1 = new SearchCriterion();
  		searchCriterion1.setAttributeName(REGION_ATTRIBUTE);
  		searchCriterion1.setOperator("like");
  		searchCriterion1.setValue("'%egion 1'");
  		SearchCriterion searchCriterion2 = new SearchCriterion();
  		searchCriterion2.setAttributeName(REGION_ATTRIBUTE);
  		searchCriterion2.setOperator("like");
  		searchCriterion2.setValue("'%egion 2'");
  		request.setCriteria(new SearchCriterion[] {searchCriterion1, searchCriterion2});
  		request.setBooleanOperator("or");
  
  		// execute
  		SearchFeatureResponse response = (SearchFeatureResponse) dispatcher.execute(
  				SearchFeatureRequest.COMMAND, request, null, "en");
  
  		// test
  		Assert.assertFalse(response.isError());
  		Assert.assertEquals(LAYER_ID, response.getLayerId());
  		List<Feature> features = Arrays.asList(response.getFeatures());
  		Assert.assertNotNull(features);
  		Assert.assertEquals(4, features.size());
  
  		List<String> actual = new ArrayList<String>();
  		for (Feature feature : features) {
  			actual.add(feature.getLabel());
  		}
  		Assert.assertTrue(actual.contains("Country 1"));
  		Assert.assertTrue(actual.contains("Country 2"));
  		Assert.assertTrue(actual.contains("Country 3"));
  		Assert.assertTrue(actual.contains("Country 4"));
  	}
test_case.class_method_signature: SearchFeatureCommandTest.testSearchMultipleCriteria()
test_case.full_signature: @Test public void testSearchMultipleCriteria()
test_case.identifier: testSearchMultipleCriteria
test_case.invocations: setLayerId setCrs setAttributeName setOperator setValue setAttributeName setOperator setValue setCriteria setBooleanOperator execute assertFalse isError assertEquals getLayerId asList getFeatures assertNotNull assertEquals size add getLabel assertTrue contains assertTrue contains assertTrue contains assertTrue contains
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testSearchMultipleCriteria()
focal_class.declarator: log  = LoggerFactory.getLogger(SearchFeatureCommand.class)
focal_class.modifier: private final
focal_class.original_string: private final Logger log  = LoggerFactory.getLogger(SearchFeatureCommand.class);
focal_class.type: Logger
focal_class.var_name: log
focal_class.declarator: configurationService
focal_class.modifier: @Autowired
  	private
focal_class.original_string: @Autowired
  	private ConfigurationService configurationService;
focal_class.type: ConfigurationService
focal_class.var_name: configurationService
focal_class.declarator: geoService
focal_class.modifier: @Autowired
  	private
focal_class.original_string: @Autowired
  	private GeoService geoService;
focal_class.type: GeoService
focal_class.var_name: geoService
focal_class.declarator: converter
focal_class.modifier: @Autowired
  	private
focal_class.original_string: @Autowired
  	private DtoConverterService converter;
focal_class.type: DtoConverterService
focal_class.var_name: converter
focal_class.declarator: filterService
focal_class.modifier: @Autowired
  	private
focal_class.original_string: @Autowired
  	private FilterService filterService;
focal_class.type: FilterService
focal_class.var_name: filterService
focal_class.declarator: layerService
focal_class.modifier: @Autowired
  	private
focal_class.original_string: @Autowired
  	private VectorLayerService layerService;
focal_class.type: VectorLayerService
focal_class.var_name: layerService
focal_class.file: command/src/main/java/org/geomajas/command/feature/SearchFeatureCommand.java
focal_class.identifier: SearchFeatureCommand
focal_class.interfaces: implements CommandHasRequest<SearchFeatureRequest, SearchFeatureResponse>
focal_class.class_method_signature: SearchFeatureCommand.getEmptyCommandRequest()
focal_class.full_signature: @Override public SearchFeatureRequest getEmptyCommandRequest()
focal_class.identifier: getEmptyCommandRequest
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: SearchFeatureRequest
focal_class.signature: SearchFeatureRequest getEmptyCommandRequest()
focal_class.class_method_signature: SearchFeatureCommand.getEmptyCommandResponse()
focal_class.full_signature: @Override public SearchFeatureResponse getEmptyCommandResponse()
focal_class.identifier: getEmptyCommandResponse
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: SearchFeatureResponse
focal_class.signature: SearchFeatureResponse getEmptyCommandResponse()
focal_class.class_method_signature: SearchFeatureCommand.execute(SearchFeatureRequest request, SearchFeatureResponse response)
focal_class.full_signature: @Override public void execute(SearchFeatureRequest request, SearchFeatureResponse response)
focal_class.identifier: execute
focal_class.modifiers: @Override public
focal_class.parameters: (SearchFeatureRequest request, SearchFeatureResponse response)
focal_class.return: void
focal_class.signature: void execute(SearchFeatureRequest request, SearchFeatureResponse response)
focal_class.class_method_signature: SearchFeatureCommand.createFilter(SearchFeatureRequest request, String layerId)
focal_class.full_signature:  Filter createFilter(SearchFeatureRequest request, String layerId)
focal_class.identifier: createFilter
focal_class.parameters: (SearchFeatureRequest request, String layerId)
focal_class.return: Filter
focal_class.signature: Filter createFilter(SearchFeatureRequest request, String layerId)
focal_method.body: @Override
  	public void execute(SearchFeatureRequest request, SearchFeatureResponse response) throws Exception {
  		String layerId = request.getLayerId();
  		if (null == layerId) {
  			throw new GeomajasException(ExceptionCode.PARAMETER_MISSING, "layer");
  		}
  		String crs = request.getCrs();
  		if (null == crs) {
  			throw new GeomajasException(ExceptionCode.PARAMETER_MISSING, "crs");
  		}
  
  		Filter filter = createFilter(request, layerId);
  		log.debug("filter to apply : {}", filter);
  
  		List<InternalFeature> features = layerService.getFeatures(layerId, geoService.getCrs(request.getCrs()), filter,
  				null, request.getFeatureIncludes(), request.getOffSet(), request.getMax());
  		response.setLayerId(layerId);
  		int max = request.getMax();
  		if (max == SearchFeatureRequest.MAX_UNLIMITED) {
  			max = features.size();
  		}
  		if (max > features.size()) {
  			max = features.size();
  		}
  		Feature[] maxList = new Feature[max];
  		for (int i = 0; i < max; i++) {
  			Feature feature = converter.toDto(features.get(i));
  			feature.setCrs(crs);
  			maxList[i] = feature;
  		}
  		response.setFeatures(maxList);
  	}
focal_method.class_method_signature: SearchFeatureCommand.execute(SearchFeatureRequest request, SearchFeatureResponse response)
focal_method.full_signature: @Override public void execute(SearchFeatureRequest request, SearchFeatureResponse response)
focal_method.identifier: execute
focal_method.invocations: getLayerId getCrs createFilter debug getFeatures getCrs getCrs getFeatureIncludes getOffSet getMax setLayerId getMax size size size toDto get setCrs setFeatures
focal_method.modifiers: @Override public
focal_method.parameters: (SearchFeatureRequest request, SearchFeatureResponse response)
focal_method.return: void
focal_method.signature: void execute(SearchFeatureRequest request, SearchFeatureResponse response)