当前位置: 首页>>代码示例>>Java>>正文


Java IndexSearcher.getDefaultSimilarity方法代码示例

本文整理汇总了Java中org.apache.lucene.search.IndexSearcher.getDefaultSimilarity方法的典型用法代码示例。如果您正苦于以下问题:Java IndexSearcher.getDefaultSimilarity方法的具体用法?Java IndexSearcher.getDefaultSimilarity怎么用?Java IndexSearcher.getDefaultSimilarity使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.lucene.search.IndexSearcher的用法示例。


在下文中一共展示了IndexSearcher.getDefaultSimilarity方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: LiveIndexWriterConfig

import org.apache.lucene.search.IndexSearcher; //导入方法依赖的package包/类
LiveIndexWriterConfig(Analyzer analyzer, Version matchVersion) {
  this.analyzer = analyzer;
  this.matchVersion = matchVersion;
  ramBufferSizeMB = IndexWriterConfig.DEFAULT_RAM_BUFFER_SIZE_MB;
  maxBufferedDocs = IndexWriterConfig.DEFAULT_MAX_BUFFERED_DOCS;
  maxBufferedDeleteTerms = IndexWriterConfig.DEFAULT_MAX_BUFFERED_DELETE_TERMS;
  readerTermsIndexDivisor = IndexWriterConfig.DEFAULT_READER_TERMS_INDEX_DIVISOR;
  mergedSegmentWarmer = null;
  termIndexInterval = IndexWriterConfig.DEFAULT_TERM_INDEX_INTERVAL; // TODO: this should be private to the codec, not settable here
  delPolicy = new KeepOnlyLastCommitDeletionPolicy();
  commit = null;
  useCompoundFile = IndexWriterConfig.DEFAULT_USE_COMPOUND_FILE_SYSTEM;
  openMode = OpenMode.CREATE_OR_APPEND;
  similarity = IndexSearcher.getDefaultSimilarity();
  mergeScheduler = new ConcurrentMergeScheduler();
  writeLockTimeout = IndexWriterConfig.WRITE_LOCK_TIMEOUT;
  indexingChain = DocumentsWriterPerThread.defaultIndexingChain;
  codec = Codec.getDefault();
  if (codec == null) {
    throw new NullPointerException();
  }
  infoStream = InfoStream.getDefault();
  mergePolicy = new TieredMergePolicy();
  flushPolicy = new FlushByRamOrCountsPolicy();
  readerPooling = IndexWriterConfig.DEFAULT_READER_POOLING;
  indexerThreadPool = new DocumentsWriterPerThreadPool(IndexWriterConfig.DEFAULT_MAX_THREAD_STATES);
  perThreadHardLimitMB = IndexWriterConfig.DEFAULT_RAM_PER_THREAD_HARD_LIMIT_MB;
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:29,代码来源:LiveIndexWriterConfig.java


注:本文中的org.apache.lucene.search.IndexSearcher.getDefaultSimilarity方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。