lucenenet-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anthony Gatlin <anthony.gat...@happycatfish.com>
Subject Visual Studio 2017 / Working Demo for Current Build
Date Tue, 30 May 2017 23:05:42 GMT
The LuceneNET GitHub site says that only Visual Studio 2015 is supported
for Lucene.NET 4.8  builds and that Visual Studio 2017 is not supported.

Can anyone provide any insight as to why Visual Studio 2017 is not
supported and if this is something that will soon be resolved?

What I am really wanting/needing to do is to actually get some kind of
functioning demo that works with the latest GitHub commit or MyGet build so
that I can actually begin learning Lucene in preparation for applying it on
a .NET Standard project.

It seems like the namespaces and methods have radically changed over the
past few versions, and I have been unable to find a single demo that
actually works on 4.8 builds.

Even Itamar Synershko's 4.8 demo (
https://channel9.msdn.com/Blogs/MVP-VisualStudio-Dev/LuceneNET-48-a-pre-release-introduction
 / https://github.com/synhershko/LuceneNetDemo ) appears to have issues.

For starters, I was unable to perform a .NET restore on  the referenced
Lucene.NET packages. When I updated them with the latest version from
MyGet, the build failed.

There is an Analyzer called the HtmlStripAnalyzerWrapper.

using System.IO;using Lucene.Net.Analysis;using Lucene.Net.Analysis.CharFilters;
namespace LuceneNetDemo.Analyzers
{
    class HtmlStripAnalyzerWrapper : Analyzer
    {
        private readonly Analyzer _wrappedAnalyzer;

        public HtmlStripAnalyzerWrapper(Analyzer wrappedAnalyzer)
        {
            _wrappedAnalyzer = wrappedAnalyzer;
        }

        public override TokenStreamComponents CreateComponents(string
fieldName, TextReader reader)
        {

            return _wrappedAnalyzer.CreateComponents(fieldName, new
HTMLStripCharFilter(reader));
        }
    }
}


The build is throwing an error here.

        public override TokenStreamComponents CreateComponents(string
fieldName, TextReader reader)
        {

            return _wrappedAnalyzer.CreateComponents(fieldName, new
HTMLStripCharFilter(reader));
        }


[image: Inline image 1]

It appears that the access modifiers for a method may have been changed
from public to protected. Being unfamiliar with Lucene, I am unsure how to
workaround the issue.

Severity Code Description Project File Line Suppression State
Error CS0507 'HtmlStripAnalyzerWrapper.CreateComponents(string,
TextReader)': cannot change access modifiers when overriding 'protected
internal' inherited member 'Analyzer.CreateComponents(string, TextReader)'
LuceneNetDemo
E:\Projects\LuceneNetDemo\LuceneNetDemo\Analyzers\HtmlStripAnalyzerWrapper.cs
16 Active

Severity Code Description Project File Line Suppression State
Error CS1540 Cannot access protected member
'Analyzer.CreateComponents(string, TextReader)' via a qualifier of type
'Analyzer'; the qualifier must be of type 'HtmlStripAnalyzerWrapper' (or
derived from it) LuceneNetDemo
E:\Projects\LuceneNetDemo\LuceneNetDemo\Analyzers\HtmlStripAnalyzerWrapper.cs
19 Active

I am new to Lucene.NET. I want to learn it. I want to use it. I am
absolutely thrilled about the possibilities it offers. I am a little
discouraged because there just do not seem to up-to-date demos or much
recent documentation.

If someone could point me in the right direction for getting a 4.8 demo
working, I would much appreciate it. I would also welcome links to any
up-to-date documentation.

Many thanks!

Mime
  • Unnamed multipart/related (inline, None, 0 bytes)
View raw message