title: StandardTokenizer overrides final method setReader.(Ljava/io/Reader;)V
body: <p>I'm trying to use <a href="http://lucene.apache.org/core/4_0_0/analyzers-common/org/apache/lucene/analysis/standard/StandardAnalyzer.html" rel="nofollow">Lucene StandardTokenizer</a> as in the code below:</p>
  
  <pre><code>import org.apache.lucene.analysis.standard.StandardAnalyzer;
  import org.apache.lucene.util.Version;
  
  public class App {
      public static void main(String[] args) throws Exception {
          // line 28 goes below
          StandardAnalyzer analyzer = new StandardAnalyzer(Version.LUCENE_40);
          // the rest is irrelevant
      }
  }
  </code></pre>
  
  <p>It is throwing <code>VerifyError</code>:</p>
  
  <pre><code>Exception in thread "main" java.lang.VerifyError: class org.apache.lucene.analysis.standard.StandardTokenizer overrides final method setReader.(Ljava/io/Reader;)V
      at java.lang.ClassLoader.defineClass1(Native Method)
      at java.lang.ClassLoader.defineClass(ClassLoader.java:791)
      at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
      at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
      at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
      at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
      at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
      at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
      at lt.App.main(App.java:28)
  </code></pre>
  
  <p>Any ideas how to fix this? Thanks a lot.</p>