Top Description Inners Fields Constructors Methods
com.ibm.icu.util

public abstract Class StringTrieBuilder

extends Object
Class Inheritance
Known Direct Subclasses
com.ibm.icu.util.BytesTrieBuilder, com.ibm.icu.util.CharsTrieBuilder
Imports
java.util.ArrayList, .HashMap

Base class for string trie builder classes.

This class is not intended for public subclassing.

Author
Markus W. Scherer
ICU Status
Stable since ICU 4.8.

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class
private abstract static class
private static class
private static class
private static class
private static class
private abstract static class
public static enum
StringTrieBuilder.Option

Build options for BytesTrieBuilder and CharsTrieBuilder.

private static class
private static enum
private static class

Field Summary

Modifier and TypeField and Description
private StringTrieBuilder.ValueNode
private HashMap<StringTrieBuilder.Node, StringTrieBuilder.Node>
private StringTrieBuilder.Node
private StringTrieBuilder.State
protected StringBuilder
strings

Deprecated This API is ICU internal only.

Constructor Summary

AccessConstructor and Description
protected
StringTrieBuilder()

Deprecated This API is ICU internal only.

Method Summary

Modifier and TypeMethod and Description
protected void
addImpl(CharSequence s, int value)

Deprecated This API is ICU internal only.
protected final void
buildImpl(StringTrieBuilder.Option buildOption)

Deprecated This API is ICU internal only.
protected void
clearImpl()

Deprecated This API is ICU internal only.
private StringTrieBuilder.ValueNode
createSuffixNode(CharSequence s, int start, int sValue)

protected abstract int
getMaxBranchLinearSubNodeLength()

Deprecated This API is ICU internal only.
protected abstract int
getMaxLinearMatchLength()

Deprecated This API is ICU internal only.
protected abstract int
getMinLinearMatch()

Deprecated This API is ICU internal only.
protected abstract boolean
matchNodesCanHaveValues()

Deprecated This API is ICU internal only.
private final StringTrieBuilder.ValueNode

Returns:

A FinalValueNode with the given value.
registerFinalValue
(int
A final value.
value
)

Makes sure that there is only one unique FinalValueNode registered with this value.

private final StringTrieBuilder.Node

Returns:

newNode if it is the first of its kind, or an equivalent node if newNode is a duplicate.
registerNode
(StringTrieBuilder.Node
Input node. The builder takes ownership.
newNode
)

Makes sure that there is only one unique node registered that is equivalent to newNode, unless BUILDING_FAST.

protected abstract int
write(int unit)

Deprecated This API is ICU internal only.
protected abstract int
write(int offset, int length)

Deprecated This API is ICU internal only.
protected abstract int
writeDeltaTo(int jumpTarget)

Deprecated This API is ICU internal only.
protected abstract int
writeValueAndFinal(int i, boolean isFinal)

Deprecated This API is ICU internal only.
protected abstract int
writeValueAndType(boolean hasValue, int value, int node)

Deprecated This API is ICU internal only.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait