From 556b96b137b524e418d4e3a7e3a59e559524cc36 Mon Sep 17 00:00:00 2001 From: Wang Bin Date: Mon, 30 Mar 2015 14:31:41 +0800 Subject: [PATCH] removed unused method/property --- jieba.go | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/jieba.go b/jieba.go index 1f5e09c..d97f935 100644 --- a/jieba.go +++ b/jieba.go @@ -9,16 +9,12 @@ import ( "sort" ) -const cacheNameFormat = "jieba.%x.cache" - var ( - // Word/Tag Map load from user dictionary - UserWordTagTab = make(map[string]string) - reEng = regexp.MustCompile(`[[:alnum:]]`) - reHanCutAll = regexp.MustCompile(`\p{Han}+`) - reSkipCutAll = regexp.MustCompile(`[^[:alnum:]+#\n]`) - reHanDefault = regexp.MustCompile(`([\p{Han}+[:alnum:]+#&\._]+)`) - reSkipDefault = regexp.MustCompile(`(\r\n|\s)`) + reEng = regexp.MustCompile(`[[:alnum:]]`) + reHanCutAll = regexp.MustCompile(`\p{Han}+`) + reSkipCutAll = regexp.MustCompile(`[^[:alnum:]+#\n]`) + reHanDefault = regexp.MustCompile(`([\p{Han}+[:alnum:]+#&\._]+)`) + reSkipDefault = regexp.MustCompile(`(\r\n|\s)`) ) type route struct { @@ -59,10 +55,6 @@ func (j *Jieba) AddEntry(entry Entry) { j.Add(entry.Word, entry.Freq) } -func (j *Jieba) CacheNameFormat() string { - return cacheNameFormat -} - func (j *Jieba) Add(word string, freq float64) { j.Freq[word] = freq j.Total += freq