Skip to content

Instantly share code, notes, and snippets.

@benwtrent
Created November 16, 2022 19:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save benwtrent/79d70d59716f0e25833c5ea84d956c12 to your computer and use it in GitHub Desktop.
Save benwtrent/79d70d59716f0e25833c5ea84d956c12 to your computer and use it in GitHub Desktop.
package org.apache.pylucene.codecs;
import org.apache.lucene.codecs.lucene95.Lucene95Codec;
import org.apache.lucene.codecs.KnnVectorsFormat;
public class PyLucene95Codec extends Lucene95Codec {
private long pythonObject;
public void pythonExtension(long pythonObject){
this.pythonObject = pythonObject;
}
public long pythonExtension() {
return this.pythonObject;
}
public void finalize() throws Throwable {
pythonDecRef();
}
public native void pythonDecRef();
/** Instantiates a new codec. */
public PyLucene95Codec() {
super();
}
public native KnnVectorsFormat getKnnVectorsFormatForField(String field);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment