急求解救方法,请大佬帮忙看看,谢了!
吻别的昔日 2020-05-15 06:06:07 void AddNews(String url, String title) throws Exception {
Document _doc = new Document();
Field titleField = new Field("title", title, Store.YES, Index.ANALYZED);
Field urlField = new Field("url", url, Store.YES, Index.ANALYZED);
_doc.add(titleField);
_doc.add(urlField);
_writer.addDocument(_doc);
}
代码中只有ANALYZED显示“ANALYZED cannot be resolved or is not a field”错误