com.hankcs.hanlp.corpus.dependency.CoNll
类 CoNLLSentence

java.lang.Object
  继承者 com.hankcs.hanlp.corpus.dependency.CoNll.CoNLLSentence

public class CoNLLSentence
extends Object

CoNLL中的一个句子

作者:
hankcs

字段摘要
 CoNLLWord[] word
          有许多行,每行是一个单词
 
构造方法摘要
CoNLLSentence(CoNLLWord[] word)
           
CoNLLSentence(List<CoNllLine> lineList)
          构造一个句子
 
方法摘要
 String[][] getEdgeArray()
          获取边的列表,edge[i][j]表示id为i的词语与j存在一条依存关系为该值的边,否则为null
 CoNLLWord[] getWordArrayWithRoot()
          获取包含根节点在内的单词数组
 String toString()
           
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

字段详细信息

word

public CoNLLWord[] word
有许多行,每行是一个单词

构造方法详细信息

CoNLLSentence

public CoNLLSentence(List<CoNllLine> lineList)
构造一个句子

参数:
lineList -

CoNLLSentence

public CoNLLSentence(CoNLLWord[] word)
方法详细信息

toString

public String toString()
覆盖:
Object 中的 toString

getEdgeArray

public String[][] getEdgeArray()
获取边的列表,edge[i][j]表示id为i的词语与j存在一条依存关系为该值的边,否则为null

返回:

getWordArrayWithRoot

public CoNLLWord[] getWordArrayWithRoot()
获取包含根节点在内的单词数组

返回:


Copyright © 2014–2015 码农场. All rights reserved.