*
* ECOMP is a trademark and service mark of AT&T Intellectual Property.
*/
-package org.onap.aai.sparky.viewandinspect.entity;
+package org.onap.aai.sparky.search;
import java.util.ArrayList;
import java.util.List;
-import org.onap.aai.sparky.suggestivesearch.SuggestionEntity;
+import org.onap.aai.sparky.search.entity.SearchSuggestion;
/**
* The Class SearchResponse.
private long processingTimeInMs;
private int totalFound;
- private List<SuggestionEntity> suggestions;
+ private List<SearchSuggestion> suggestions;
/**
* Instantiates a new search response.
*/
public SearchResponse() {
- this.suggestions = new ArrayList<SuggestionEntity>();
+ this.suggestions = new ArrayList<SearchSuggestion>();
this.processingTimeInMs = 0;
this.totalFound = 0;
}
this.totalFound = totalFound;
}
- public List<SuggestionEntity> getSuggestions() {
+ public List<SearchSuggestion> getSuggestions() {
return suggestions;
}
- public void setSuggestions(List<SuggestionEntity> suggestions) {
+ public void setSuggestions(List<SearchSuggestion> suggestions) {
this.suggestions = suggestions;
}
*
* @param suggestionEntry that will be converted to JSON
*/
- public void addSuggestion(SuggestionEntity suggestionEntity) {
+ public void addSuggestion(SearchSuggestion suggestionEntity) {
suggestions.add(suggestionEntity);
}
public void addToTotalFound(int additionalCount) {
totalFound += additionalCount;
}
+
+ @Override
+ public String toString() {
+ return "SearchResponse [processingTimeInMs=" + processingTimeInMs + ", totalFound=" + totalFound
+ + ", " + (suggestions != null ? "suggestions=" + suggestions : "") + "]";
+ }
+
+
+
}