Skip to content

Instantly share code, notes, and snippets.

@benwtrent
Created July 7, 2025 19:05
Show Gist options
  • Select an option

  • Save benwtrent/35b047193773b5b7249d047b2985bc74 to your computer and use it in GitHub Desktop.

Select an option

Save benwtrent/35b047193773b5b7249d047b2985bc74 to your computer and use it in GitHub Desktop.
package org.apache.pylucene.codecs;
import org.apache.lucene.codecs.lucene100.Lucene100Codec;
import org.apache.lucene.codecs.KnnVectorsFormat;
public class PyLucene100Codec extends Lucene100Codec {
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 PyLucene100Codec() {
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