throw new SearchException(e);
}
// execute the query
engine = SearchEngineFactory.createSearchEngine(criteria, result, context, messageBroker);
SearchEngineCSW csw = (SearchEngineCSW) engine;
csw.setResourceLinkBuilder(rBuild);
csw.doSearch(cswRequest);
// handle a request against a remote repository
} else {
// create the criteria, execute the query