if(type==SearchIndex.TYPE_CUSTOM) {
required("index",action,"body",body);
//required("index",action,"query",query);
}
IndexResult result;
// FUTURE remove this condition
if(collection instanceof LuceneSearchCollection)
result = ((LuceneSearchCollection)collection).index(pageContext,key,type,urlpath,title,body,language,extensions,query,recurse,categoryTree,category,timeout,custom1,custom2,custom3,custom4);
else