|
||||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
java.lang.Objectcom.hankcs.hanlp.collection.MDAG.SimpleMDAGNode
public class SimpleMDAGNode
The class capable of representing a MDAG node, its _transition set, and one of its incoming transitions; objects of this class are used to represent a MDAG after its been simplified in order to save space.
| 构造方法摘要 | |
|---|---|
SimpleMDAGNode()
|
|
SimpleMDAGNode(char letter,
boolean isAcceptNode,
int transitionSetSize)
Constructs a SimpleMDAGNode. |
|
| 方法摘要 | |
|---|---|
char |
getLetter()
Retrieves the character representing the _transition laben leading up to this node. |
int |
getOutgoingTransitionSetSize()
Retrieves the size of this node's outgoing _transition set. |
int |
getTransitionSetBeginIndex()
Retrieves the index in this node's containing array that its _transition set begins at. |
boolean |
isAcceptNode()
Retrieves the accept state status of this node. |
boolean |
load(ByteArray byteArray)
|
void |
save(DataOutputStream out)
写入 |
void |
setTransitionSetBeginIndex(int transitionSetBeginIndex)
Records the index in this node's containing array that its _transition set begins at. |
String |
toString()
|
SimpleMDAGNode |
transition(SimpleMDAGNode[] mdagDataArray,
char letter)
Follows an outgoing _transition from this node. |
SimpleMDAGNode |
transition(SimpleMDAGNode[] mdagDataArray,
char[] str)
|
SimpleMDAGNode |
transition(SimpleMDAGNode[] mdagDataArray,
char[] str,
int offset)
|
SimpleMDAGNode |
transition(SimpleMDAGNode[] mdagDataArray,
String str)
Follows a _transition path starting from this node. |
static SimpleMDAGNode |
traverseMDAG(SimpleMDAGNode[] mdagDataArray,
SimpleMDAGNode sourceNode,
String str)
Follows a _transition path starting from the source node of a MDAG. |
| 从类 java.lang.Object 继承的方法 |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| 构造方法详细信息 |
|---|
public SimpleMDAGNode(char letter,
boolean isAcceptNode,
int transitionSetSize)
letter - a char representing the _transition label leading to this SimpleMDAGNodeisAcceptNode - a boolean representing the accept state status of this SimpleMDAGNodetransitionSetSize - an int denoting the size of this _transition setpublic SimpleMDAGNode()
| 方法详细信息 |
|---|
public char getLetter()
public boolean isAcceptNode()
public int getTransitionSetBeginIndex()
public int getOutgoingTransitionSetSize()
public void setTransitionSetBeginIndex(int transitionSetBeginIndex)
transitionSetBeginIndex - an int denoting the index in this node's containing array that is _transition set beings at
public SimpleMDAGNode transition(SimpleMDAGNode[] mdagDataArray,
char letter)
mdagDataArray - the array of SimpleMDAGNodes containing this nodeletter - the char representation of the desired _transition's label
letter,
or null if there is no such labeled _transition from this node
public SimpleMDAGNode transition(SimpleMDAGNode[] mdagDataArray,
String str)
mdagDataArray - the array of SimpleMDAGNodes containing this nodestr - a String corresponding a _transition path in the MDAG
str, or null if such a _transition path is not present in the MDAG
public SimpleMDAGNode transition(SimpleMDAGNode[] mdagDataArray,
char[] str)
public SimpleMDAGNode transition(SimpleMDAGNode[] mdagDataArray,
char[] str,
int offset)
public static SimpleMDAGNode traverseMDAG(SimpleMDAGNode[] mdagDataArray,
SimpleMDAGNode sourceNode,
String str)
mdagDataArray - the array containing the data of the MDAG to be traversedsourceNode - the dummy SimpleMDAGNode which functions as the source of the MDAG data in mdagDataArraystr - a String corresponding to a _transition path in the to-be-traversed MDAG
str, or null if such a _transition path is not present in the MDAGpublic String toString()
Object 中的 toString
public void save(DataOutputStream out)
throws Exception
ICacheAble 复制的描述
ICacheAble 中的 saveExceptionpublic boolean load(ByteArray byteArray)
ICacheAble 中的 load
|
||||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||