org.carrot2.text.suffixtree
Class SuffixTreeBuilder

java.lang.Object
  extended by org.carrot2.text.suffixtree.SuffixTreeBuilder

public final class SuffixTreeBuilder
extends Object

Builds a suffix tree using method chains, thus avoiding direct dependency on specialized constructors of SuffixTree.

See Also:
from(ISequence), build()

Method Summary
 SuffixTree build()
           
static SuffixTreeBuilder from(ISequence sequence)
          Returns the builder for a suffix tree made from sequence.
 SuffixTreeBuilder withProgressCallback(SuffixTree.IProgressCallback callback)
           
 SuffixTreeBuilder withStateCallback(SuffixTree.IStateCallback callback)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

from

public static SuffixTreeBuilder from(ISequence sequence)
Returns the builder for a suffix tree made from sequence.


build

public SuffixTree build()
Returns:
Return a new suffix tree according to current parameters. This method call may take a long time, depending on the length of the input sequence.

withProgressCallback

public SuffixTreeBuilder withProgressCallback(SuffixTree.IProgressCallback callback)

withStateCallback

public SuffixTreeBuilder withStateCallback(SuffixTree.IStateCallback callback)


Copyright (c) Dawid Weiss, Stanislaw Osinski