本文整理匯總了Golang中github.com/BurntSushi/goim/imdb.DB.IsFuzzyEnabled方法的典型用法代碼示例。如果您正苦於以下問題:Golang DB.IsFuzzyEnabled方法的具體用法?Golang DB.IsFuzzyEnabled怎麽用?Golang DB.IsFuzzyEnabled使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類github.com/BurntSushi/goim/imdb.DB
的用法示例。
在下文中一共展示了DB.IsFuzzyEnabled方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Golang代碼示例。
示例1: New
// New returns a bare-bones searcher with no text to search. Once all options
// are set, the search can be executed with the Results method. Each result
// returned corresponds to precisely one entity in the database.
//
// (A bare-bones searcher can still have text to search with the Query method.)
func New(db *imdb.DB) *Searcher {
return &Searcher{
db: db,
fuzzy: db.IsFuzzyEnabled(),
limit: 30,
goodThreshold: 0.25,
similarThreshold: 0.4,
what: "entity",
}
}