C# 클래스 LevenshteinAutomaton.Trie

Prefix tree
파일 보기 프로젝트 열기: ibendrup/LevenshteinAutomaton

공개 프로퍼티들

프로퍼티 타입 설명
root TrieNode

공개 메소드들

메소드 설명
AddWord ( String word ) : void

Append word to the prefix tree

GetNode ( String argString ) : TrieNode

Get node for given word or prefix

GetPrefix ( String prefix ) : TrieNode

Get node for given prefix if exists

GetWord ( String word ) : TrieNode

Get node for given word if exists

Trie ( ) : System

Init empty prefix tree

Trie ( IEnumerable lexicon ) : System

Init prefix tree for given lexicon

СontainsPrefix ( String prefix ) : bool

Check if trie contains given prefix

СontainsWord ( String word ) : bool

Check if trie contains given word

비공개 메소드들

메소드 설명
Сontains ( String argString, bool word ) : bool

Check if trie contains given word or prefix

메소드 상세

AddWord() 공개 메소드

Append word to the prefix tree
public AddWord ( String word ) : void
word String
리턴 void

GetNode() 공개 메소드

Get node for given word or prefix
public GetNode ( String argString ) : TrieNode
argString String
리턴 TrieNode

GetPrefix() 공개 메소드

Get node for given prefix if exists
public GetPrefix ( String prefix ) : TrieNode
prefix String
리턴 TrieNode

GetWord() 공개 메소드

Get node for given word if exists
public GetWord ( String word ) : TrieNode
word String
리턴 TrieNode

Trie() 공개 메소드

Init empty prefix tree
public Trie ( ) : System
리턴 System

Trie() 공개 메소드

Init prefix tree for given lexicon
public Trie ( IEnumerable lexicon ) : System
lexicon IEnumerable
리턴 System

СontainsPrefix() 공개 메소드

Check if trie contains given prefix
public СontainsPrefix ( String prefix ) : bool
prefix String
리턴 bool

СontainsWord() 공개 메소드

Check if trie contains given word
public СontainsWord ( String word ) : bool
word String
리턴 bool

프로퍼티 상세

root 공개적으로 프로퍼티

Root of the tree
public TrieNode,LevenshteinAutomaton root
리턴 TrieNode