public class RelatedTermsDictionaryBuilder
extends com.exalead.gni.GNIObject
Constructor and Description |
---|
RelatedTermsDictionaryBuilder(MOTPipeInterface pipe)
Initialize a new builder
|
RelatedTermsDictionaryBuilder(MOTPipeInterface pipe,
java.lang.String filename)
Initialize a new builder from an existing resource
|
Modifier and Type | Method and Description |
---|---|
boolean |
add(byte[][] rts,
int[] langs,
long[] freqs) |
boolean |
add(byte[] rt,
int lang,
long freq)
Add a related term
|
boolean |
add(byte[] rt,
int lang,
long freq,
int kid)
Add a related term
|
boolean |
compile(java.lang.String filename)
Compile the resource
|
protected void |
finalize() |
long |
get(byte[] rt,
int lang) |
long |
getNbRelatedTerms() |
void |
updateFreqDForm(long kid,
java.lang.String displayForm,
long freq) |
void |
updateFreqDForms(long[] kids,
java.lang.String[] displayForms,
long[] freqs) |
public RelatedTermsDictionaryBuilder(MOTPipeInterface pipe, java.lang.String filename)
pipe
- The pipe to usefilename
- An existing resource pathpublic RelatedTermsDictionaryBuilder(MOTPipeInterface pipe)
pipe
- The pipe to usepublic boolean add(byte[] rt, int lang, long freq, int kid)
rt
- The encoded RT, with words, kinds and a display formlang
- The languagefreq
- The frequencykid
- The keyword ID, forced if != 0public boolean add(byte[] rt, int lang, long freq)
rt
- The encoded RT, with words, kinds and a display formlang
- The languagefreq
- The frequencypublic boolean add(byte[][] rts, int[] langs, long[] freqs)
public long getNbRelatedTerms()
public long get(byte[] rt, int lang)
public void updateFreqDForm(long kid, java.lang.String displayForm, long freq)
public void updateFreqDForms(long[] kids, java.lang.String[] displayForms, long[] freqs)
public boolean compile(java.lang.String filename)
filename
- The output fileprotected void finalize()
finalize
in class java.lang.Object
Copyright © 2013 Dassault Systèmes, All Rights Reserved.