IndexReader reader = null; try { reader = m_indexSource.getReader(); Term idTerm = m_beanAdaptor.getIdentityTerm(bean, id); reader.delete(idTerm); } catch (IOException e) { throw new RuntimeException(e); } finally { LuceneUtils.closeQuietly(reader);
if (m_beanAdaptor.indexClass(new Document(), bean.getClass())) { internalRemoveBean(bean, id);
    public void removeBean(Object bean, Serializable id) {        IndexReader reader = null;        try {            reader = m_indexSource.getReader();            Term idTerm = m_beanAdaptor.getIdentityTerm(bean, id);            reader.delete(idTerm);        } catch (IOException e) {            throw new RuntimeException(e);        } finally {            LuceneUtils.closeQuietly(reader);        }    }