comparison lucene/src/luan/modules/lucene/LuceneSearcher.java @ 481:5d4a78c93383

luan errors are now tables
author Franklin Schmidt <fschmidt@gmail.com>
date Mon, 11 May 2015 20:26:36 -0600
parents dae264ad6a7b
children c5a93767cc5c
comparison
equal deleted inserted replaced
480:44caaa6a3d92 481:5d4a78c93383
90 if( nObj instanceof LuanFunction ) { 90 if( nObj instanceof LuanFunction ) {
91 final LuanFunction fn = (LuanFunction)nObj; 91 final LuanFunction fn = (LuanFunction)nObj;
92 Collector col = new MyCollector() { 92 Collector col = new MyCollector() {
93 @Override public void collect(int doc) { 93 @Override public void collect(int doc) {
94 try { 94 try {
95 LuanTable docTbl = doc(luan,docBase+doc); 95 try {
96 luan.call(fn,new Object[]{docTbl}); 96 LuanTable docTbl = doc(luan,docBase+doc);
97 luan.call(fn,new Object[]{docTbl});
98 } catch(IOException e) {
99 throw luan.exception(e);
100 }
97 } catch(LuanException e) { 101 } catch(LuanException e) {
98 throw new LuanRuntimeException(e); 102 throw new LuanRuntimeException(e);
99 } catch(IOException e) {
100 throw new LuanRuntimeException(luan.exception(e));
101 } 103 }
102 } 104 }
103 }; 105 };
104 try { 106 try {
105 searcher.search(query,col); 107 searcher.search(query,col);