I'm interested in technologies(solutions) that permits Java and .NET interoperate. I have tried the following and it works but I would like to know if there are other solutions:
有谁知道其他技术(解决方案)能够实现Java和.NET的互操作性或Java和.NET互操作性的最佳实践?
我想在SOLR查询中启用"startsWith"搜索每个术语,但也能够执行短语搜索(在引号中给出).对于前缀搜索首先我添加了后缀"*".此解决方案允许前缀搜索和短语搜索,但我不喜欢此解决方案,因为它是通配符搜索,通配符搜索不分析条款.
所以我只在索引时启用了EdgeNgramFilterFactory.前缀搜索工作正常,但确切的短语搜索不再起作用.
有没有人知道如何启用短语搜索,即使启用了EdgeNgram?
谢谢!
这是schema.xml
<fieldType name="text" class="solr.TextField" positionIncrementGap="100">
      <analyzer type="index">
        <tokenizer class="solr.WhitespaceTokenizerFactory"/>
        <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
    <filter class="solr.EdgeNGramFilterFactory" minGramSize="1" maxGramSize="50" side="back" />
    <filter class="solr.EdgeNGramFilterFactory" minGramSize="1" maxGramSize="50" side="front" />
        <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="1" catenateNumbers="1" catenateAll="0" splitOnCaseChange="1"/>
        <filter class="solr.LowerCaseFilterFactory"/>
        <filter class="solr.KeywordMarkerFilterFactory" protected="protwords.txt"/>
        <filter class="solr.PorterStemFilterFactory"/>
        <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
      </analyzer>
      <analyzer type="query">
        <tokenizer class="solr.WhitespaceTokenizerFactory"/>
        <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
        <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
        <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="1"/>
        <filter class="solr.LowerCaseFilterFactory"/>
        <filter class="solr.KeywordMarkerFilterFactory" protected="protwords.txt"/>
        <filter class="solr.PorterStemFilterFactory"/>
        <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
      </analyzer>
    </fieldType>
Run Code Online (Sandbox Code Playgroud)
另外我注意到当使用WordDelimiterFilterFactory时,突出显示不再表现良好.