Controller/SearchControllerTrait.php
public function autocompleteAction(Request $request) {
		$term = $request->get('term');
		return new JsonResponse($this->searchService->autocomplete($term, $this->getSuggestionCount()));
	}
public function autocompleteAction(Request $request) {
		$term = $request->get('term');
		return new JsonResponse($this->searchService->autocomplete($term, $this->getSuggestionCount()));
	}
public function autocompleteAction ( Request $ request ) { $ term = $ request -> get ( 'term' ) ; return new JsonResponse ( $ this -> searchService -> autocomplete ( $ term , $ this -> getSuggestionCount ( ) ) ) ; }
Returns a JSON array of autocompletions for the given term.
The term can be provided as a GET or POST paramater with the name <em>term</em>

@param Request $request
@return \Symfony\Component\HttpFoundation\JsonResponse
Returns a JSON array of autocompletions for the given term . The term can be provided as a GET or POST paramater with the name <em > term< / em >