PHP 클래스 TextAnalysis\Corpus\WordnetCorpus

저자: yooper
상속: extends ReadCorpusAbstract
파일 보기 프로젝트 열기: yooper/php-text-analysis 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$exceptionsMap TextAnalysis\Models\Wordnet\ExceptionMap[]
$lemmas TextAnalysis\Models\Wordnet\Lemma[]
$lexNames stores all the lex names
$posFileMaps map part of speech character to its definition
$synsets TextAnalysis\Models\Wordnet\Synset[] An array with indexing. Indexing is pos with offset concatenated

공개 메소드들

메소드 설명
getDataFileNames ( ) : string[]
getExceptionFileNames ( ) : array Returns array of file names with the exceptions
getExceptionMapFromString ( string $line, string $pos ) : ExceptionMap
getExceptionsMap ( ) : ExceptionMap[] Returns the list of exception spellings
getFileNames ( ) : string[] Returns the list of required files that is provided by the nltk project
getIndexFileNames ( ) : string[]
getLemmaFromString ( string $line ) : Lemma
getLemmas ( ) : Lemma[]
getLexNames ( ) : string[]
getPosFileMaps ( ) : array
getSynsetByOffsetAndPos ( integer $synsetOffset, string $pos ) : Synset Opens the raw data file and reads the synsets in
getSynsetFromString ( string $line ) : Synset Parse the line from the synset file and turn it into a synset object

메소드 상세

getDataFileNames() 공개 메소드

public getDataFileNames ( ) : string[]
리턴 string[]

getExceptionFileNames() 공개 메소드

Returns array of file names with the exceptions
public getExceptionFileNames ( ) : array
리턴 array

getExceptionMapFromString() 공개 메소드

public getExceptionMapFromString ( string $line, string $pos ) : ExceptionMap
$line string
$pos string
리턴 TextAnalysis\Models\Wordnet\ExceptionMap

getExceptionsMap() 공개 메소드

Returns the list of exception spellings
public getExceptionsMap ( ) : ExceptionMap[]
리턴 TextAnalysis\Models\Wordnet\ExceptionMap[]

getFileNames() 공개 메소드

Returns the list of required files that is provided by the nltk project
public getFileNames ( ) : string[]
리턴 string[]

getIndexFileNames() 공개 메소드

public getIndexFileNames ( ) : string[]
리턴 string[]

getLemmaFromString() 공개 메소드

public getLemmaFromString ( string $line ) : Lemma
$line string
리턴 TextAnalysis\Models\Wordnet\Lemma

getLemmas() 공개 메소드

public getLemmas ( ) : Lemma[]
리턴 TextAnalysis\Models\Wordnet\Lemma[] Returns an array of lemmas

getLexNames() 공개 메소드

public getLexNames ( ) : string[]
리턴 string[]

getPosFileMaps() 공개 메소드

public getPosFileMaps ( ) : array
리턴 array

getSynsetByOffsetAndPos() 공개 메소드

Opens the raw data file and reads the synsets in
public getSynsetByOffsetAndPos ( integer $synsetOffset, string $pos ) : Synset
$synsetOffset integer
$pos string Part of speech
리턴 TextAnalysis\Models\Wordnet\Synset

getSynsetFromString() 공개 메소드

Parse the line from the synset file and turn it into a synset object
public getSynsetFromString ( string $line ) : Synset
$line string
리턴 TextAnalysis\Models\Wordnet\Synset

프로퍼티 상세

$exceptionsMap 보호되어 있는 프로퍼티

protected ExceptionMap[],TextAnalysis\Models\Wordnet $exceptionsMap
리턴 TextAnalysis\Models\Wordnet\ExceptionMap[]

$lemmas 보호되어 있는 프로퍼티

protected Lemma[],TextAnalysis\Models\Wordnet $lemmas
리턴 TextAnalysis\Models\Wordnet\Lemma[]

$lexNames 보호되어 있는 프로퍼티

stores all the lex names
protected $lexNames

$posFileMaps 보호되어 있는 프로퍼티

map part of speech character to its definition
protected $posFileMaps

$synsets 보호되어 있는 프로퍼티

An array with indexing. Indexing is pos with offset concatenated
protected Synset[],TextAnalysis\Models\Wordnet $synsets
리턴 TextAnalysis\Models\Wordnet\Synset[]