Documentation
¶
Index ¶
- Constants
- type AutoComplete
- type Dictionary
- func (dict *Dictionary) Add(word string)
- func (dict *Dictionary) AddAll(words []string)
- func (dict *Dictionary) Clear()
- func (dict *Dictionary) Count() int
- func (dict *Dictionary) ForSomeWords(callback func(string, string, int) bool)
- func (dict *Dictionary) List() []string
- func (dict *Dictionary) Remove(word string)
Constants ¶
View Source
const MIN_RANK = -10000
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AutoComplete ¶
type AutoComplete struct {
Dict *Dictionary
}
func Create ¶
func Create() *AutoComplete
func (*AutoComplete) GetMatches ¶
func (ac *AutoComplete) GetMatches(pattern string, count int) []*pq.Item
type Dictionary ¶
type Dictionary struct {
// contains filtered or unexported fields
}
func (*Dictionary) Add ¶
func (dict *Dictionary) Add(word string)
func (*Dictionary) AddAll ¶
func (dict *Dictionary) AddAll(words []string)
func (*Dictionary) Clear ¶
func (dict *Dictionary) Clear()
func (*Dictionary) Count ¶
func (dict *Dictionary) Count() int
func (*Dictionary) ForSomeWords ¶
func (dict *Dictionary) ForSomeWords(callback func(string, string, int) bool)
func (*Dictionary) List ¶
func (dict *Dictionary) List() []string
func (*Dictionary) Remove ¶
func (dict *Dictionary) Remove(word string)
Click to show internal directories.
Click to hide internal directories.