![JAR search and dependency download from the Maven repository](/logo.png)
test.it.unimi.dsi.big.mg4j.query.nodes.DoublingTermExpander Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of mg4j-big Show documentation
Show all versions of mg4j-big Show documentation
MG4J (Managing Gigabytes for Java) is a free full-text search engine for large document collections written in Java. The big version is a fork of the original MG4J that can handle more than 2^31 terms and documents.
The newest version!
package it.unimi.dsi.big.mg4j.query.nodes;
import it.unimi.dsi.lang.MutableString;
public class DoublingTermExpander extends AbstractTermExpander {
@Override
public Query expand( Term term ) {
return new MultiTerm( term, new Term( new MutableString( term.term ).append( term.term ) ) );
}
@Override
public Query expand( Prefix prefix ) {
return new MultiTerm( new Term( prefix.prefix ), new Term( new MutableString( prefix.prefix ).append( prefix.prefix ) ) );
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy