paramsMap.put( "callback", callback );
//Creating an utility response object
ResourceResponse responseResource = new ResourceResponse( paramsMap );
List<ContentletSearch> searchIndex = APILocator.getContentletAPI().searchIndex(query, limit, offset, sortBy, initData.getUser(), true);
JSONArray array=new JSONArray();
for(ContentletSearch cs : searchIndex) {
array.put(new JSONObject()
.put("inode", cs.getInode())
.put("identifier", cs.getIdentifier()));
}
return responseResource.response( array.toString() );
}