MIFOSX-2038 : cleanup

This commit is contained in:
pramod
2015-08-27 15:04:40 +05:30
parent 80f122446a
commit 87adf49f44
2 changed files with 47 additions and 4 deletions
@@ -9,6 +9,7 @@ import java.util.Collection;
import java.util.Set;
import javax.ws.rs.Consumes;
import javax.ws.rs.DefaultValue;
import javax.ws.rs.GET;
import javax.ws.rs.POST;
import javax.ws.rs.Path;
@@ -72,11 +73,8 @@ public class SearchApiResource {
@Consumes({ MediaType.APPLICATION_JSON })
@Produces({ MediaType.APPLICATION_JSON })
public String searchData(@Context final UriInfo uriInfo, @QueryParam("query") final String query,
@QueryParam("resource") final String resource ,@QueryParam("exactMatch") Boolean exactMatch) {
@QueryParam("resource") final String resource ,@DefaultValue("false") @QueryParam("exactMatch") Boolean exactMatch) {
if (exactMatch == null) {
exactMatch = false;
}
final SearchConditions searchConditions = new SearchConditions(query, resource,exactMatch);
final Collection<SearchData> searchResults = this.searchReadPlatformService.retriveMatchingData(searchConditions);