Created
July 7, 2025 19:05
-
-
Save benwtrent/35b047193773b5b7249d047b2985bc74 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 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