protected void reindexEntries(long companyId) throws PortalException,
SystemException {
final Collection<Document> documents = new ArrayList<Document>();
ActionableDynamicQuery actionableDynamicQuery = new EntryActionableDynamicQuery() {
@Override
protected void addCriteria(DynamicQuery dynamicQuery) {
}
@Override
protected void performAction(Object object) throws PortalException {
Entry entry = (Entry) object;
Document document = getDocument(entry);
documents.add(document);
}
};
actionableDynamicQuery.setCompanyId(companyId);
actionableDynamicQuery.performActions();
SearchEngineUtil.updateDocuments(getSearchEngineId(), companyId,
documents);
}